A nanny accused of decapitating a young girl in her care then walking through the street brandishing the head, said "Allah ordered" the killing as she appeared at a Moscow court.