Besides salary Green Carders don't quit.
Once a worker has an H1-B, they can jump ship to any company that will sponsor them. They don't need a new H1-B. They can remain on that H1-B for up to six years.
Workers with green cards can leave to any company whenever they want.
All H-1B and green card holders undermine US workers. But you are correct the guy I trained was an H-1b visa holder but I am sure he eventually became green card holder.
The quotas for H-1B is filled every year. I guess they are profitable.