One never knows exactly what Allah is up to.
As a certain pastor I know keeps reminding us, Satan is not God. He’s not omniscient, he’s not all-powerful, he’s not omnipresent, he’s not eternal. He has a temporary, limited role that the true God is allowing him.