The riddle
What Is Orange and Sounds Like a Parrot?
An anti-riddle
A normal riddle hides a clever answer. This one hides nothing. It lists a color and a sound, and the listener starts hunting through tropical birds and talking toys. The answer is a carrot, which makes no noise at all. "Sounds like" does not mean "makes a sound like". It means "rhymes with". Carrot and parrot differ in their first sound only, and Merriam-Webster gives both the same ending.
Why orange fits
Britannica notes that carrots come in several colors, including yellow, white and purple, though the orange ones are the type most shoppers know. The orange comes from carotene, a pigment, and the pigment is named after the vegetable, from the Latin word for carrot (Merriam-Webster, "carotene"). The color in the question and the word in the answer therefore go back to the same plant.
The parrot half
Britannica describes parrots as birds known for bright feathers and, in some kinds, for copying human speech. The riddle uses none of that. It only borrows the word, and the sound of the word is all that matters. A listener who fixates on the bird has taken the bait the question laid out.
Making up a pair
The pattern works with any rhyming pair: choose a color and a thing that rhymes with an animal. A group can try coming up with one for a different bird. If the rhyme has to be forced, it usually does not work, and the carrot and parrot pair is a good test of how clean a rhyme needs to be.