All perfect praise be to Allah, The Lord of the Worlds. I testify that there is none worthy of worship except Allah, and that Muhammad is His slave and Messenger.
The matter of these students is one of these three situations:
First case: Being young, most of them do not know the conditions of women, the basic principle in women teaching these pupils is the permissibility because there is nothing to prevent it. They are referred to by the Quran; Allah Says (what means): {… or children who are still unaware of private aspects of women.} [Quran 24:31]
Second case: Being adults, and the woman’s teaching to these students is likely to lead to temptation, especially since teaching them requires mixing with them in most cases. Therefore, it is not permissible for her to teach them unless there is a need for that, on the condition that the woman wears full Hijab and follows religious etiquette during the lesson.
Third case: If they are adolescents close to puberty, who most likely reached or exceeded ten years of age but have not reached puberty yet, then the ruling about them is the same as adults, as it appears.
It is more appropriate for male teachers to teach male students. As for the young ones, it is for the reason of the fear that they will acquire feminine characteristics from their teachers due to the frequent contact with them or admiration for the teacher. As for adults and those close to puberty, it is to prevent the reasons of temptation.
Allah knows best.