Teacher saw something they thought was stupid. They made a power play. Saw kid work around it and took it personally. Asserted limited authority.
Being a teacher is a tough job. Thing is, just like with therapy: If you’ve reached the point where you’re going to throw around that authority willy-nilly, you are no longer a leader, you’re a bully. Fuck off and work somewhere else.
Course this may not be the whole story. Could be the kid had been a nuisance for months before this point with the sharpie bag being the excuse a child’s mind would focus on when other behaviors were the real cause.