The poet says that the squirrel wore a question mark for its tail because the shape of a squirrel’s tail resembles a question mark.
Usually, it is said that an animal ‘has’ a tail. The poet has used ‘wore’ in the poem in order to make an image of what he saw. This is an example of imagery.
The use of the word ‘wear’ in different situations can be shown with the help of the following sentences:
My friend was wearing yellow on Sunday.
Our Science teacher always wears a smile.
Movie stars wear their hair in different ways.
The squirrel is teasing the poet and his friends. When they ran around its tree, it went the other way.