It's not, though. It's not a random wooden gate in the middle of some unguarded park. It's a TEMPLE that is still in use by Buddhist monks, inside world heritage site. A 17 year old kid knows to gauge that difference.
It was at Toshodaiji, which is a 1200 year old very well maintained temple and a designated UNESCO world heritage site. I am very doubtful that he could be unaware of what the temple is, as its very much a tourist attraction and not just some random buildings. He is a kid, so I dont think it merits anything extreme in terms of punishment but the crime in this case is pretty serious. But he is 17 and definitely knew better. Any adult would likely face legal consequences.
Very much like the person who recently scratched their name into the Colosseum and claimed they did not realize it was so old. If you are not aware of the ancient nature of Rome, why the hell are you even visiting? That is like the whole point of going.