Every word has a form (what it looks like) and a function (what it does). Prepositions are words like, up, down, over, under, around (i.e., anything a cat can do). When a preposition heads a phrase, the phrase is called a prepositional phrase, like this,
EX: on the street
EX: under the table
EX: to the store
If a prepositonal phrase answers the question Where? or When? or How? or Why?, it functions as an adverbial phrase. For example,
EX: They went to the library. Where?
EX: The bus comes at 5:00. When?