GitLab as OAuth identify provider

We use GitLab as an OAuth authentication identify provider for Netlify CMS.
Previously everything worked as it should. Later, after upgrade to GitLab Community Edition v16.8.1, we can’t login to Netlify CMS.
We see this response on GitLab:

An error has occurred
The authorization server does not support this response type

How to fix it?