WATERVILLE, Maine — A federal grand jury has indicted a Waterville man who was planning an ISIS-inspired attack in February.

Court documents say Xavier Pelkey, 18, is facing a grand jury charge of knowingly possessing unregistered destructive devices.

Pelkey was arrested on Feb. 11 by agents with the Federal Bureau of Investigation, during which agents allegedly found a number of hand-painted ISIS flags, along with three homemade explosives.

The explosives reportedly contained various items, including staples and thumb tacks, that were meant to maximize injuries if the explosives were detonated.

Pelkey also allegedly colluded with two teenagers — one from Kentucky and one from the Chicago area — over social media to plan the attack according to recently unsealed documents from an FBI investigation, NBC News reported in March.

Pelkey and the two unnamed teenagers had reportedly planned for the attack to occur during “spring break”.

One of the teenagers said that the group had planned to infiltrate the mosque, separate the children from the adults and then “murder the adults” in the name of ISIS, the national news network reported.

Pelkey remains in custody pending a court date.

BDN writer Leela Stockley contributed to this report.