When I was in 2nd grade, I was denied restroom use for not knowing how to properly ask to be excused. I phased my request as, "Can I please go to the bathroom?" Mrs. Miller, who everyone called Mrs. Miller the Killer, told me I couldn't use the restroom until I learned how to ask. She never told me how to ask, so I repeated it. She denied. I tried "pretty-please" and she denied. At some point, I figured out she required me to to say 'may I' rather than 'can I.' I was 7.
I also didn't have a name in her class, I had a number. All the kids were numbered and she only referred to us by those numbers.
Some people are just absolute a**holes. And children are easy targets for a weak adult.