IONIC 4 angular routing doubts about back button

I’m using a side menu for my app navigation

Let’s say I’m already logged into the app, I’m now on the home page, I open the side menu and I navigate to another page like this, using routerLink
Once on the new page, I can click the native android back button as much as I want but it doesn’t go back to the home page, good that’s what I want
And that is the behaviour for all the navigation done through the side menu, but when I navigate programatically, android back button works, which I do not want, for example after I log in, I’m doing this
image and once I’m on the home page I can click the android native back button and it will literally take me back to the login page, how can I have the same behaviour in programatical navigation as I do through the side menu navigation, meaning, after navigating the back button won’t work