macOS Containers is a tool created by a group of developers based on chroot, which allows you to use Docker to run macOS images on macOS.
macOS Containers official website writes :
Containers fundamentally change the way modern software is developed and deployed. A variety of operating systems, including FreeBSD, Solaris, Linux and even Windows, support containers, but macOS does not natively support containers - until now the birth of macOS Containers.