Rules of Golf - Loose impediments
Rules
Loose impediments in Bunkers and Penalty Areas

You are allowed to move/remove loose impediments in bunkers and penalty areas but you need to be very careful around your ball, you would be penalised under Rule 9.4b if you cause your ball at rest to move while attempting to remove a loose impediment.