A prepositional phrase functions as an adjective when it modifies a noun or pronoun in the sentence.
A star is a huge nebula of gas.
The nearest star to our sun is Proxima Centauri.
Sirius is the brightest star in our sky.
A group of stars that appear close together is called a star cluster.
In the above sentences, the prepositional phrases of gas, to our sun, in our sky, and of stars modify the nouns nebula, star, and group.