Schools are often a very unsafe place for LGBT children. I myself developed severe depression in high school and almost lost my life to it. Trans kids in particular are often alienated and constantly misgendered which causes dysphoria. They also are more likely to be bullied or be rejected by their own parents. This is why we must protect them and support them. Supporting transgender students' rights will protect their safety. Suicide risk is very high in LGBT kids, as well as risk of physical harm from bullying.
School is a place where all kids should feel safe so that they can learn and prepare for their future.