French prepositions link two related parts of a sentence. In word order, they are placed in front of a noun in order to specify the relationship between the noun and the verb, adjective, or other noun that precedes it. [Source]
J'
ai
besoin
d'
un
médecin.
I need a doctor.