Git strategy is not working

I have a project with submodules. I have set the GIT_STRATEGY: clone and GIT_SUBMODULES_STRATEGY: recursive in the gitlab-ci.yaml. I even set the projects CI/CD settings to clone in Gitlab.
When the pipeline is run it is showing

Fetching changes with git depth set to 50... 
 Initialized empty Git repository in /home/gitlab-runner/builds/sQyEDY43/0/ejar3/ejar3-docker/.git/`

It says Fetching.... Why isn’t the submodules are not recursively being pulled down ?