Install chewmail by entering the following commands in the terminal:
sudo apt update sudo apt install chewmail
mail archiver for various mailbox formats
chewmail is a Perl-based mail archiver. It uses Mail::Box so supports any mailbox format it does. It can filter messages into mbox's based on the message's date and other criteria.