Redzepagic was charged Saturday with attempting to provide material support to ISIS. A lawyer says he has cooperated with law enforcement and needs counseling.

A bail hearing was scheduled later Monday.

The Department of Justice said Redzepagic, who lives in Commack with his parents, traveled to the Middle East twice in the past two years to attempt to join a foreign terrorist organization. Specifically, in 2015 Redzepagic allegedly communicated with an individual he believed to be the commander of a battalion in Syria and made attempts to join him to engage in jihad.

He traveled to Turkey in July 2015 and made several attempts to cross the border into Syria to join his contact’s organization, according to the DOJ.

Unable to enter Syria from Turkey, federal authorities say he traveled to Jordan in August 2016 but was stopped and deported by Jordanian authorities.

In October 2015, Redzepagic allegedly made several inflammatory posts to social media, explaining that “jihad” is when you “fight for the sake of God” and “die for the sake of Allah,” adding that he traveled to Turkey to “perform Jihad and join Jabhat Al-Nusra.” In subsequent interviews with law enforcement officials, he allegedly admitted that he was prepared to strap a bomb to himself when he attempted to enter Syria from Turkey.

When Suffolk County police arrested the Commack man on a minor offense in early February, he allegedly told them, “I’m going to leave this country, and I’m going to come back with an army. Islam is coming,” 1010 WINS’ Samantha Liebman reported.

The NYPD said Redzepagic was also arrested Tuesday at Midtown South for jumping a turnstile.

“This defendant made numerous attempts to travel to Syria to wage violent jihad,” US Attorney Robert Capers said. “We will continue to track down and prosecute individuals like the defendant before they are able to become foreign fighters or harm the United States and its allies.”

“Redzepagic, a U.S. citizen living in Long Island, made multiple attempts to join ISIS or al-Nusrah Front in Syria where he wanted to engage in violent jihad, which could have resulted in the death of countless individuals” said Special Agent in Charge, Angel Melendez of Homeland Security Investigation, New York. “This arrest underscores the importance of cooperation between law enforcement agencies across the globe in identifying and bringing these extremists to justice before they are able to commit terrorist attacks.”

CBS2’s Erin Logan spoke with a neighbor who said he’s friends with Redzepagic’s brother from high school. He said Redzepagic was known for getting into some trouble in school, but his arrest comes as a surprise.

“No he was never really supporting anything or trying to get other people to support his views or his causes, but I mean who knows,” Perry Notarnicola said.

Other neighbors said they were alarmed to learn of the arrest.

“I can’t even imagine it. I think there has to be something wrong with them, mentally, to even want to do that,” Rose Bonn said.

“I can’t believe it’s in your own backyard. It’s just amazing what’s going on in this world now,” Sharon Ross said.

Redzepagic is originally from Montenegro, in the Balkans, prosecutors said.