Every contractor should do this and the illegal problem will vanish.
You want to get paid for your work? Work in a country where you’re legal.
In this situation the contractor is guilty of the crime hiring an illegal for work.
While I see your reasoning there’s something about working a guy all day and not paying him. This contractor is not doing this to help the country. He’s the lowest form of whales*&t there is and I have no doubt that he’s done it to Americans too.