A simile is a figure of speech that compares two different things using "like" or "as." In the phrase:
“when like a roe / I bounded o’er the mountains”
(from Wordsworth’s Tintern Abbey)
The speaker compares himself to a roe (a small deer), using "like" to draw the comparison — a textbook example of a simile.
“Like a roe” = the comparison
“Bounded o’er the mountains” = emphasizes lightness, energy, and freedom of youth.