Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

AMSTERDAM — A man who stabbed two American tourists at Amsterdam's central station last week named Dutch, anti-Islam lawmaker Geert Wilders during police questioning and said he was motivated by perceived insults to Islam in the Netherlands, prosecutors said on Monday.

The man, identified by Dutch media as Jawed S., is a 19-year-old Afghan with residency in Germany, who traveled to Amsterdam to carry out an attack because of what he said were repeated insults to God, the Koran and Islam's Prophet Mohammed, prosecutors said in a statement.

Geert Wilders, left, speaks to the media in Antwerp, Belgium, on Sept. 2, 2018. Julien Warnand / EPA

The attack came after Wilders, a far right campaigner against Islam, canceled plans to hold a competition last week of cartoons depicting the Prophet Mohammed and had a clear "terrorist motive," prosecutors said.

"He named Wilders, but did not say anything about the cartoon competition," a statement said. "Up to now there is no evidence the suspect worked with others."

The victims, both 38-year-old men, are still being treated at a hospital. The suspect, who was shot and wounded by police, was also being treated, and his custody was extended Monday for two weeks.

Prosecutors said German police had searched the man's home in Germany and seized computer memory devices.