The lump of labor fallacy is usually covered in “basic economics” classes. There are multiplier effects from clustering of certain types of skilled workers. This increases overall demand and thus overall compensation for everyone in the market.
This is why ending the H1B program like posters propose here would be profoundly stupid - if companies can’t staff their teams here, they will staff them elsewhere, and either stop hiring here or close up shop entirely. This will lower salaries and increase unemployment in the relevant fields.
You already see this in microcosm due to real estate costs serving as a brake on internal migration, many companies have moved all net new hiring out of the Bay Area.
Now admit too many foreign workers at too low wages and you will hit diminishing returns, but we are way short of that point, especially if we can manage to curb abuses of the existing program.