A North Carolina man accused of decapitating his own mother has been found not guilty of murder by reason of insanity.

Oliver Funes Machada was ordered to remain in custody of a state mental hospital after a Franklin County judge ruled Monday that psychosis drove him to commit the March 2017 murder.

Doctors determined Machada had a condition similar to schizophrenia.

After the killing, the teen allegedly told a 911 dispatcher he did it “because I felt like it,” according to sworn statements reported by WNCN in Raleigh last year. He then allegedly walked out of his home “carrying a knife in one hand and a severed human head in the other,” according to an affidavit cited by the station. Police found “a decapitated body on the floor [of the home] between the kitchen and the living room and two small children inside." The kids, Machada’s 4-year-old sister and 2-year-old brother, were unharmed.

A public defender described Machada last year as a “pretty profoundly disturbed young man,” according to the Charlotte Observer. Last year, Machada was ruled too incompetent to proceed in court, but a doctor testified Monday his condition had improved enough to finish the case.

"When I first saw him, he admitted that he was hearing a voice telling him that he should kill me and then a voice warning him that the correctional officer that was guarding us was going to shoot me, so you could imagine how tormenting it would be to constantly be exposed to that sort of an experience," Dr. George Corvin, a forensic psychiatrist, testified in court, according to WNCN.

Machada said little in court but told the judge he understood the proceeding. He also apologized to his family.

The Associated Press has contributed to this report.

[Photo: Franklin County Sheriff's Office via AP]

Crime Time is your destination for true crime stories from around the world, breaking crime news, and information about Oxgen's original true crime shows and documentaries. Sign up for our Crime Time Newsletter and subscribe to our true crime podcast Martinis & Murder for all the best true crime content.