When you try to delete a folder in “View Messages”, the program requires that it be empty of messages and other folders. If it’s not, it will not allow you to delete it. You simply need to start at the “lowest” folder, remove the emails by moving them or deleting, then move or remove that folder.
This is because if you delete a folder with messages or other folders in it, the program has to decide what to do with those messages and folders. It’s best if you explicitly decide where they should go rather than WAM deciding where to move them.