How to configure Apple Mail on iPhone XR (iOS 12.4) to download emails from mailserver but not delete them on it?
Sure. Have Apple mail client use IMAP protocol to leave a copy on the server and just don’t delete on iOS. 

Next time your machine deletes things off the server, the next IMAP sync will clean up things on the iPhone automagically.