Why did God allow Satan and the demons to sin?

This article has been translated into the following languages: