“There is no place for violence in Islam,” Imam Syed Wadood Janud said.
He said the Muslim community was shocked by the incident.
“This was so close to home - any one of us could have been at Bunnings,” he said.
Imam Wadood Janud said the Muslim community was worried about a possible backlash.
“We’re extremely concerned about Islamophobia,” he said.
“Sometimes the backlash can be very harsh.”
The teen, who was known to police and had mental health and online radicalisation issues, was taken to hospital and declared dead about 11pm on Saturday.
An injured man in his 30s was found close by with a stab wound and transported to Royal Perth Hospital where he remains in a serious but stable condition.
Western Australian Police Commissioner Col Blanch said the Caucasian teen had acted alone during the attack, which appeared to be random because he had no connection to his victim.
He also said the boy was part of a de-radicalisation support programme treating extremism since 2022.
Members of the Muslim community concerned by the teen’s behaviour after he posted messages online had contacted police before the incident.
“We believe he sent relevant messages to some of those members who immediately responded by calling police,” Blanch said.
“I do want to thank members of the Muslim community who did that because that enabled us to identify rapidly who this individual was and respond quickly.”
Minister for Home Affairs Clare O’Neil thanked the Muslim community members who contacted police with concerns about the teen.
“There is no place for violent extremism in Australia,” she said in post on social media platform X.