MathLab has GHC 9.4.8 (Haskell interpreter and compiler). Newer versions are very likely to be compatible in this course.
Via GHCup.
For “enable better integration of stack with GHCup?” you can answer no. (It doesn't matter in this course, yes is not wrong either.)
Please also pay attention to its reminders about system requirements.
Please don't use Ubuntu/Debian's “apt-get install ghc
”, it really
is too old for this course.
If you prefer keeping the Haskell compiler inside a docker image: Standard docker images for Haskell.
Or, development container in VS Code: There is a definition for Haskell. (Basically it runs GHCup in a devcontainer for you.) Perhaps these instructions helps.