The Scottish government will sponsor care home workers after Sir Keir Starmer changed the skilled worker visa this year, Scotland's first minister has announced.