In Netflix's Marco Polo (which I understand is not the most historically accurate show in the world), we see Chingis Khan and Kublai Khan use flocks of flaming sparrows and [SPOILERS] a herd of flaming horses against enemy encampments, to incite terror and panic and set fire to buildings and structures.
Was this tactic ever employed?
Pigs have been used as countermeasures against war elephants in the third through first centuries BC. Flaming pigs were recorded by Polyaenus and by Aelian. Both writers reported that Antigonus II Gonatas' siege of Megara in 266 BC was broken when the Megarians doused some pigs with combustible pitch, set them alight, and drove them into the enemy's war elephants.
Sources: Kistler, J. 2005, 2007. "War Elephants."
Aelian, "On Animals Volume 1"
Snorri Sturluson records in the Heimskringla that Harald Sigurdsson used flaming birds to capture a Sicilian town. After he set fire to them they returned back to their nests in the town, which were under the thatched roofs of the town's buildings. The buildings started to burn, and the townspeople ran out, begging for mercy. I'm not sure what modern historians think of this episode, but there definitely is some precedent for what you described in the show.