Two Iowa teenagers killed their high school Spanish teacher with a baseball bat last year due to a bad grade, prosecutors said.

According to court documents that were filed on Tuesday and obtained by Associated Press, prosecutors said Willard Miller, 17, was upset with Nohema Graber, a 66-year-old Spanish teacher at Fairfield High School, due to the low grade he received in Spanish class that affected and lowered his GPA.

Miller and Jeremy Goodale, 17, have been charged with first-degree murder in connection with the death of Graber. According to People, this alleged motive behind the murder was revealed for the first time this week. 

The documents filed by Jefferson County Attorney Chauncey Moulding and Assistant Iowa Attorney General Scott Brown said: "the poor grade is believed to be the motive behind the murder of Graber, which directly connects Miller."

Miller initially denied having anything to do with Graber's disappearance and murder, but according to the documents, he "later stated he had knowledge of everything but did not participate."

READ NEXT: 2 Iowa Teens Ambushed Their Spanish Teacher, Dragged Her Into Woods, Then Killed Her Before Returning to Hide Her Body 

One of the Iowa Teenagers Meets the Spanish Teacher on the Day of Murder

In the documents presented this week to a judge in Iowa, the prosecutors said Willard Miller met with his high school Spanish teacher on the afternoon of the murder to discuss the low grade he got from her class.

Aside from his poor grade in the Spanish class, the prosecutors noted that Miller was also frustrated with the way Nohema Graber taught Spanish in her class, the Independent reported.

According to the investigators, hours after meeting Miller, Graber drove her van to a local park where she always takes a walk every day after work. There, the Iowa teenagers allegedly ambushed the Spanish teacher and beat her to death with a baseball bat before hiding her body.

The detectives said witnesses saw two guys driving Graber's van from the site 42 minutes after she arrived at the park. The vehicle was later found abandoned along a rural road.

Investigators noted that a witness later picked up the two Iowa teenagers on the same road after Goodale called them for a lift.

Iowa Teenagers Initially Denied the Murder, but Later Shared Their Crime on Snapchat

Nohema Graber's body was discovered in the park on November 3, 2021, hidden under a tarp, wheelbarrow, and railroad ties. The Spanish teacher had been beaten to death with a baseball bat. The two suspects were 16 at the time.

According to court documents, Willard Miller claimed that a "roving group of masked youngsters" killed Graber and ordered him to dispose of the body as he denied any role in the Spanish teacher's death.

The Iowa teenagers told the police that the real killers were a "roving group of masked kids" who forced them to bring a wheelbarrow to help move her body and take her van out of the park, NBC News reported.

According to the documents, a witness sent photos of a Snapchat conversation in which the other teen admitted that they "acted in concert with another person to bring about Graber's death."

The witness recognized the teen as having made comments that implicated both teenagers by name. Christine Branstad, Miller's lawyer, requested that the search warrants and evidence found in her client's home be invalidated and suppressed.

She claimed that the search warrants were issued illegally in part as "law enforcement failed to provide information to the issuing magistrate to show the informant is reliable or that the information from the informant should be considered reliable."

Miller's trial is on March 20 in Council Bluffs, and Goodale's is on December 5 in Davenport. Both teens will be tried as adults. The first-degree murder penalty in Iowa is life in prison.

According to decisions made by the Iowa Supreme Court, juveniles convicted of even the most serious offenses must be given a chance for parole.

READ MORE: Justin Verlander and Kate Upton Move to Florida After Selling California Home to Timothee Chalamet for $11M 

This article is owned by Latin Post.

Written by: Bert Hoover

WATCH: Was Teacher Murdered for Giving a Student a Bad Grade? - From Inside Edition