This is true to some extent, but sometimes you really do need a specialist. Some fields, such as databases and machine learning, are deep enough that there is a huge difference between someone learning it on the job and someone who has been doing it for 10 years.
I think it also might be easier to get interviews and job offers for specialist positions where there's less demand. I'm not prepared to make a strong case for that, but I did feel like selling myself as a Ruby on Rails developer made certain portions of technical interviewing a lot more straight forward than when I was interviewing for "I'm a software engineer" roles. Just a feeling.