This is a tough one. There isn't really a clear paradigm of the rules of school at home online vs in person. Some of the same rules at school apply at home. There are things you can't do in school online that you can't do at school.
Teachers across the country are mandatory reporters. If they see a gun on the screen, or somebody being abused, or drugs/ paraphernalia, they have to report it.
I have heard several stories. Another kid with an obvious green toy gun in Colorado, a kid with a toy gun in Jersey. The grandma yelling about politics. Trump flags, etc.
This kid was not pointing it at the screen. He wasn't pretending to shoot people with it. At the same time, if other kids see a gun on the screen not knowing if it is real or not they could feel threatened, be traumatized. Schools have to make examples.
Still, this kid was being responsible. Maybe the school should have investigated and taken that into account. He didn't mean to put it on the screen.
School policies are blankets though, there is no messing around or room for objectivity.