Coastal areas will have to rely on more migration or face a decline in their workforce, according to government figures.