At the lower levels of chemistry, first of all, reactions in aqueous solutions or water and only a few other types of reactions are learned.
The reaction of sodium with sodium hydroxide is not in this range, but that doesn't mean it can't occur. Besides, this reaction requires conditions that are rather impossible to meet at school or in a student university laboratory (~ 600°C).