Toddlers understand what is 'right' and 'wrong' far more clearly than we thought
Psychologists say babies know right from wrong even at six months
Knowing that some things are right and others wrong is an early thing kids pick up. If you constantly shout at a baby who cries, sooner or later that kid, growing up, will associate crying with anger from others and will be afraid to cry. Kids even understand concepts like death at much, much earlier ages than past generations.
I think this kid's trial at 12, while still insanely young, is justified. He knows right from wrong, he knew what he was doing, he conspired to do it with his friends and in the end, regardless of his emotional state or whether he actually intended for it to happen or not, it did anyway.
And he appears to have a good attitude about it. He admits wrongdoing, he doesn't seem to blame anyone else for his own actions and he takes responsibility for it. He can, in the future, help other kids who ended up just like him.