PTSD?
Assuming it wasn’t murder then he was in a sorry state to drive him to go to an outbuilding and kill himself behind a locked door knowing his poor parents would have to find him and deal with it.
So PTSD seems a plausible reason. Survivor’s guilt is a real thing. Whatever he was going through..it all became too much for him.