Packaging a MATLAB Docker image is supported on Linux only. However, the resulting Docker image can be executed on all the 3 platforms: Windows, Linux and macOS.
To run a Docker image in macOS, you need to have Docker Desktop and XQuartz (for GUI apps) installed.
You can find instructions to create a Docker image for MATLAB, Simulink and any other toolboxes you are using in the following link:
The MATLAB Docker container can be found here in dockerhub:
Please note that this Docker container has been tested for Ubuntu 20.04 only.
Hope this helps!