The Court of the City Magistrate declared the mosque illegal last month and issued an order for its demolition