I've run my own mail server for over 15 years. If you're going to do it, put it on a VM at a reliable cloud provider, such as AWS. You wouldn't want your email to go down while you're on vacation for a week with no way of fixing it. You need to make sure you use a static IP that you keep forever, because your mail server builds reputation and the IP must not have any reputation of spam that has landed it on block lists.
It's not difficult if you let reuse someone else's hard work to make it secure and keep it updated. This project is fantastic: https://mailinabox.email/
Would I recommend it? It's more rational to bring your own domain to have it hosted by Microsoft or Google, but doing it yourself is more fun and flexible, and possibly cheaper depending on how many users and domains you will be hosting.
I've run my own mail server for over 15 years. If you're going to do it, put it on a VM at a reliable cloud provider, such as AWS. You wouldn't want your email to go down while you're on vacation for a week with no way of fixing it. You need to make sure you use a static IP that you keep forever, because your mail server builds reputation and the IP must not have any reputation of spam that has landed it on block lists.
It's not difficult if you let reuse someone else's hard work to make it secure and keep it updated. This project is fantastic: https://mailinabox.email/
Would I recommend it? It's more rational to bring your own domain to have it hosted by Microsoft or Google, but doing it yourself is more fun and flexible, and possibly cheaper depending on how many users and domains you will be hosting.