In a suicide note, she accused the teacher of "torturing" her.
Although the girl did not mention period shaming in her letter, the mother says her daughter was asked to leave the class because of the stain.
Menstruation is taboo in parts of rural India. Women are traditionally believed to be impure during their periods.
Police say they have registered a case of suicide and are investigating. The incident took place early on Sunday in Tirunelveli district in the state of Tamil Nadu.
"I do not know why my teacher is making complaints against me. I still can't understand why they are harassing and torturing me like this," the student said in her suicide note.
It began: "Amma [mother], please forgive me."
Her mother accused the teacher of having beaten her daughter in the past for not doing her homework.
''My daughter got her periods while she was in school last Saturday," her mother told BBC Tamil. "When she informed the teacher, she was given a duster cloth to use as a pad.
"The teacher made my daughter stand outside the class. How can a 12-year-old withstand such humiliation?" she asked.
The girl killed herself a day later.
The school told the BBC it was co-operating with police.