Whether it is legal is an interesting question. I would say yes, it is legal as there is no law addressing the issue specifically. I would contact his teacher and ask him/her to explain herself. If the explanation is still unsatisfactory, I would go to the principal and file a complaint. As for legal intervention, I just don't think it rises to the level of a court case. If it happened every day for a month, I might have a different opinion.