Erm … what do you mean?
I use IMAP, but all my mails are stored in Thunderbird on my PC, NOT online. I created storage folders (like for shops, people, etc) and move all my emails, sent and received, into those folders and have emails going back well over a decade in there. That way I don’t have to rely on online storage (which I agree is a security issue) but still use the better IMAP service. I was using my folder setup back in the POP3 days too btw.
The only time emails are on my phones is before I move them in Thunderbird, and if for some reason I still need an email on my phone (package tracking numbers for example) I just keep that in my inbox until I’m finished with it and then move it.