Morgan arrived at the Old Bailey accompanied by five mental health nurses who have been supporting him.

He was dressed in a dark blue suit and an open necked white shirt as he confirmed his name and date of birth.

Morgan was visibly in tears as the case was outlined and through his barrister, Michael Stradling, told the court that Morgan wanted the judge to know he was “very sorry”.

Mitigating, Stradling told the court that Morgan had no history of violence and that the greater risk was “of self-harm or the defendant suffering harm at the hands of others”.

The court heard that Morgan had been deemed a “high risk to others and to himself” after overhearing conversations that took place since he has been in custody.

Morgan could not be identified previously during the trial because of his age, but the restriction was lifted on his 18th birthday.

The prosecution said: “The risk of radicalisation of other vulnerable young children is a possibility.”

The court was told that youth offending service have “significant reservations about managing your risk in the community”.