In the Full Folder List, right-click the IMAP4 account folder, and then click Sort Subfolders.
This option is not available if the folders are already alphabetized.