No doubt, some "heroic deeds" were invented.
The classic one, I think, is a story of Aryobarzan.
About 150 years after the Battle of Thermopilae (the 300 Spartans story), Alexander the Great invaded Persia. With a comparatively small force, he annihilated Persian forces time and time again.
The humiliated Persians counteracted with the story of a heroic Persian commander Aryobarzan who, with a small force, held the gigantic Greek army at bay in a mountain pass. A local shepherd betrayed him by showing the Greeks a secret pass around.
Well, this is the exact repetition of the Leonidas' story, only the sides were reversed!
I spoke with a former Professor of History in Teheran University and she just chuckled: according to her, this story was a well-known hoax invented by the humiliated Persians and passed from generation to generation. Kind of psychological compensation..... But just Google this name: hundreds of hits in Iran, from hotels to tours! Heroism, especially invented, can be commercially profitable

.