How difficult expensive that is depends on the country you are in - not all countries have a fire-at-will type legal system.
Also having frequent rounds of firings impacts company culture - making it much more transactional ( everyone for themselves ) - some companies value their employees and culture and the collaboration and long term thinking that can bring.
One option that's increasingly common is hiring people on fix term contracts - however that does create a sort of divide.