Here's why:
* Adverbs modify verbs, adjectives, or other adverbs. In this case, "on" modifies the verb "shine," telling us where the stars shine.
* Prepositions often act as adverbs. "On" is a preposition, but it's functioning as an adverb in this sentence because it modifies the verb "shine."
Let me know if you have any other questions!