Plenty of people have two passports for this reason.
Lots of things in immigration require you to honestly self-report and have no mechanism to validate at the point-of-entry. For instance, many countries without visa requirements will still ask about criminal records in your native country, but have no access to the data to verify if you tell them you've never even had a parking ticket.
But if you get caught later down the line, then they are going to use your lies to make life very hard for you.
Using two passports is not always the solution. As a dual citizen of two countries, I also have two passports. A couple of years ago I travelled to Malta with the passport from the country I currently live in. One week later I flew over to Israel, where I used the passport of my birth country. I was extensively interrogated at the border, because apparently the system flagged me to the border officer as there was no record of me entering Malta with the passport I attempted to leave the country with.
Interesting. But, TBH, it seems pretty obvious in the hindsight: it's a huge red flag that the travel history in the same passport is not self-consistent (as a result of using different passports for entering and leaving the same country).
I always wondered if this would get flagged somehow. I've never tried it myself, but I've thought about doing it.
What I was mentioning though is that countries will let you have a second passport from a single country if you have issues like this, to avoid showing the stamps in one passport.
Lots of things in immigration require you to honestly self-report and have no mechanism to validate at the point-of-entry. For instance, many countries without visa requirements will still ask about criminal records in your native country, but have no access to the data to verify if you tell them you've never even had a parking ticket.
But if you get caught later down the line, then they are going to use your lies to make life very hard for you.