A Wisconsin jury on Friday found that a girl who admitted to participating in the stabbing of a classmate to please a fictional character named Slenderman was not guilty by reason of mental disease or defect, CNN reported.

The decision by the Waukesha County Circuit Court jury decision sends Anissa Weier, 15, to a state mental hospital, where she will not be able to seek a conditional release until July 2020, Reuters reported.

"I'm very thankful to the jurors for taking the time to look at what was really going on with her," said Weier’s attorney, Maura McMahon.

According to investigators, in May 2014 Weier and Morgan Geyser lured classmate Payton Leutner into the woods at a park in Waukesha, Wisconsin. Geyser stabbed Leutner 19 times while Weier urged her on, according to investigators. A passing bicyclist found Leutner, who barely survived her wounds. All three girls were 12 at the time.

Both Weier and Geyser told detectives they felt they had to kill Leutner to become Slenderman's "proxies," or servants, and protect their families from the demon's wrath.

Weier, now 15, pleaded guilty to attempted second-degree intentional homicide in a deal with prosecutors in August. But she claimed she was mentally ill during the attack and not responsible for her actions, in a bid to be sent to a mental institution rather than prison. A plea agreement called for her to spend at least three years in a mental hospital if judged mentally ill, and 10 years in prison if not.

Slenderman, a fictional internet character, is a paranormal being who lurks near forests and absorbs, kills or carries off his victims. In some accounts, he targets children. Some renderings show him as a long-limbed, lean man in a black suit, with no face; others with tentacles protruding from his back.

"This sounds crazy, because it is," McMahon said. "This was a real being to this child and she needed to protect those around her. At 12 years old, she had no way to protect herself from (Slenderman) except for Morgan's advice and they swirled down into madness together."