Following classroom rules should not stifle her spirit - it is an important lesson for our little ones to learn as we all have rules of conduct to comply with throughout life - school, work, social situations, etc.
My son is now 15, he is smart, and funny, and strong willed and stubborn. I have struggled with his compliance with the rules in school, since kindergarten when he would sit under the table because "I already learned that in pre-school" - and he was right - he already covered much of the kindergarten work in pre-school, but diving under the table was not acceptable classroom behavior.
In 2nd grade he decided he didn't need to take tests because the teacher already knew that he could do the work so the test was a waste of time - this was his mindset.
In 6th grade he butted heads with his teacher - while I did not like her style either, she was the teacher and, as such, he needed to listen to her in class. His response was to not do the work - he figured if he flunked, it would lower the classes grade point average, and since "teachers jobs are tied to student performance" he could get her fired. Amazing logic, albiet skewed, from a 6th grader - he made sure to pass the class - as he could do the work, but he made sure it was just barely because he was determined to stick to his theory that he could get her fired. No, she was not. LOL
Long way around the bushes to say - your daughter will run into many teachers throughout her school career that she will not mesh with - personalities are different and not all children love every teacher they have ever had (think back, I am sure you can remember some you did not like either). But, she will have to learn to cope with teachers, co-workers, classmates, that she does not like. This will not crush her spirit - if my son is any example - his spirit is still very high despite teachers he did not like.
As her mother, you can promote her independent spirit at home, in extracurricular activities, etc., while teaching her how to get along with difficult people. Find out of school activities that will promote her creativity and outgoing manner. It will provide a balance to the rules of school.
Following the rules is not a bad thing - I follow them every day at work, while I am driving, etc. but I still maintain an independent spirit and strong sense of self. Rather like my son :)
And just like your daughter will be - strong, independent, but able to cope with others in a responsible manner.