If you are referring to gmail...
when viewing a message, you can click the little file cabinet icon on the bottom left, to archive. In gmail, a mail with no labels is considered "archived". When it first comes into your inbox, it will have the "inbox" label. So hitting the archive button is the same as removing the "inbox" label, which you can do also by clicking on the "inbox" label on the message, which will give you a dropdown to select which labels you want on the message. There is also a "change labels" icon at the bottom that does the same thing. If you wanted to move the message to a folder, gmail calls that a label, so you apply the label you want here. You can apply more than one, which is the advantage of labels over folders, at the expense of being confusing, at first.