It has labels, of which you can apply one or more of to a message. When represented in IMAP, it appears as folders (though you get duplicate mail objects for every additional folder that a mail is tagged with).
If you only apply only one label to a mail at a given time, it works as a folder would do just fine.