So teachers are not allowed to have opinions about students, or to have a private life.
Certainly can. Just not if they want to have sex with a minor or if they would like to kill a child. Being stupid always has consequences!
There’s a big difference between TALKING about having sex with or killing someone and actually DOING it. While this conversation may have been indiscreet and in poor taste, it certainly isn’t criminal.