You will want a couple things. First get yourself some VoIP phones. Yealink is a decent brand. Grand stream Wave is a good option for Android and iOS softphones.
Secondly download a PBX. I recommend Fusion PBX others will recommend 3cx but the main thing is to avoid Asterisk.
Finally get yourself a SIP trunk from a phone provider.
Now cry in pain as you are constantly bombarded with SIP attacks in your home.