Similar to Nicaragua, the flag of Spain includes a little bit of purple in the coat of arms, which has a purple lion representing the ancient kingdom of León. That lion is sometimes depicted in dark red, but it is traditionally and more correctly purple.
http://www.spain-flag.eu/colours.htm,
https://en.wikipedia.org/wiki/Coat_of_arms_of_Castile_and_Leon
So, Spain's is a *third* national flag with purple, to add to the previously mentioned Dominica and Nicaragua.
Then there's the constitutionally-recognised second flag of Bolivia, the Wiphala, which includes violet/purple in its multicoloured design, making the tally four, sort of...
https://en.wikipedia.org/wiki/Wiphala
Some sources claim that the coat of arms on the flag of Belize also includes purple, but this is not shown or described by its government at
https://belize.com/belize-flag/.
Yet another tiny rainbow with purple is found in the symbol in the centre of the Flag of El Salvador. This symbol (and flag) is very similar to Nicaragua's, since they were both once part of the same republic that used its own very similar design.
https://en.wikipedia.org/wiki/Coat_of_arms_of_El_Salvador,
https://www.worldatlas.com/flags/el-salvador
That makes *five* national flags with purple.
The flag of Qatar may look purple to some, but it is officially maroon and white.
https://www.worldatlas.com/flags/qatar
Maroon is also a dominant colour in Sri Lanka's flag.
https://www.worldatlas.com/flags/sri-lanka