It is customary to wear costumes on Purim, and this custom has strong basis in Halacha. However, it is forbidden for men to dress up as women, and vice versa (Devarim 22:5)
Children, too, should not be allowed to dress up as the opposite gender. The Rishonim (Medieval Halachic scholars), including the Rambam and Rabbi Eliezer of Metz, who write explicitly that dressing as a member of the opposite gender is forbidden under all circumstances, without exception. In their view, this is forbidden even if it is done only temporarily and as a joke.
The Rabbis certainly have no power to suspend the explicit Torah prohibition against wearing the clothes of the opposite gender.
Adopted from the class of Rabbi Eli Mansour