This may be a little controversial, but I think people that pray for bad things to happen or cast spells on people should be held accountable as if they've actually physically attempted the act. It would be difficult to prosecute but if someone truly believes praying or casting spells has a real world effect and they use magic or pray for bad things, to me that's no different than someone thinking a gun was loaded and trying to shoot someone with it. Even though there is zero chance of hurting anyone, they believe when they aim the gun at someone and pull the trigger that they will hurt or kill that person, and the same is true of someone that believes in prayer or magic and tries to hurt someone with it. To me the crime is in the intent.
For what purpose would we do that? We would charge someone who pointed a gun at someone and pulled the trigger thinking it was loaded because society has a legitimate interest in discouraging that behavior. Because even if the gun was not loaded it is conceivable that it was. We punish attempted murder in this way because we want to prevent actual murder. We don't do it because we are punishing people for thought crimes, we do it because because we have an interest in discouraging this behavior.
But this does not apply to "magic spells". The is no such thing as a loaded magic ("honestly officer, I didn't think the magic wand was loaded"). If we lived in a universe where some magic spells worked and some didn't, then I might see a point to charging someone even if they used a spell that didn't work. But that is not the universe we live in. Or imagine if we lived in a universe where guns never fired under any circumstances (but they were still produced and kept by people for some unknown reason). If guns never fired it would not be a crime to point one at somebody and shoot, and society would have no interest in preventing that behavior.
Also keep in mind that in this case the person casting the "spell" was not an adult. She was a child. And not only a child, she was a student. The person the "spell" was cast on was a teacher. A person whose job it is to educate the student. If I was that teacher I would encourage that student to cast hundreds of "spells" on me. And even give extra credit for it. And that way she would learn that "spells" do not work (right, education, that is what school should be about).