Fascist? really, have you ever lived under fascism or dictatorship?
This is welcome to the real world kid, infact this should never have happened I don't understand how would anyone over 12 would think that a petition at your workplace could or should work.
You don't know what circumstances was she working at, you don't know why they were ordered to wear dress clothes (uniforms are pretty damn good for instilling discipline).
Now I understand you situation and you also need to understand that not everyone has to be accepting of your situation including your employer this is perfectly acceptable without being discriminatory.
You work as a programmer which means that you can wear pretty much what you want as long as you do not meet business clients or customers but not everyone else is in the same position as you.
Some employees end up handling people, some of them just end up being in sight of customers, I don't care what you wear when you code something in a cubicle, but I don't want the worker in a funeral home wearing some crap, or my lawyer in a courtroom.
And you are right the company you work for does not own you, but the same goes the other way, it does not owe you anything either. It provides you with an environment in which you can trade your time for pay under a set of agreed circumstances if you do not agree to follow those guidelines you can find another place that allows you to trade your time for money under more palatable or acceptable terms.
So yes this has everything to do with "millennials" or well considering that I am one, entitlement and more like it than not way too many years of pampering by her parents and the educational system that had it's balance of power turned upside down that led her to believe she can just do everything if she signs a petition no matter how passive aggressive her behaviour is in reality.
But overall good for you for not accepting anyone to have an effect on your appearance but with all due respect that's your personal choice you can't claim it to be more important than the company you might work for one day wanting to present a specific image of it's employees that conflicts with your own personal dress code.
At that moment you'll have a choice how much does your external look and what you wear affect who you actually are, if they are that big part of your life that you can't simply change it well then you are at an impasse but please don't make it to be that you somehow are better than a company that has a dress code when you have one too.