You have to make sure that well-understood criteria is followed for layoffs, or else the action might be understood as a firing. [1]
This is important, because a company can be held liable for wrongful termination. [2]
[1] https://www.nolo.com/legal-encyclopedia/making-layoff-decisi...
[2] https://www.employmentlawfirms.com/resources/employment/wron...