Immigrants are occupying either the low end jobs that nobody wants, like what you get in agriculture (e.g. strawberry pickers - if you don't know how that's like, try it out ;-)), cleaning services, etc, or they are occupying the high end jobs, like what you get in Silicon Valley, an industry that creates jobs, or say medical doctors, which are hired because of their expertise or to lower the prices, which in the end translates to lower healthcare bills, etc.
Either way, if you ban immigration, you'll get automation, or a crashing economy due to other countries being more competitive. And if you get automation, it's worse than immigrants, because those immigrants are spending their salaries locally, whereas robots don't get salaries.
You know, it's funny you should say that. I'm from an ex-communist country from Eastern Europe and let me tell you, the problem with communism was the extreme inefficiency due to the state's incentive of keeping people hired which ultimately led to hunger and the fall of the USSR.