Gitlab Creates Ephemeral Volumes by default

I am trying to mount a PV with RWX mode using the below code in the gitlab-runner.

    [[runners.kubernetes.volumes.csi]]
      name = "csi-volume"
      mount_path = "/path/to/csi/volume"
      driver = "my-csi-driver"
      [runners.kubernetes.volumes.csi.volume_attributes]
        size = "2Gi"

The PVC is present in the same namespace as that of runner. Also, I am able to mount this PVC in any other deployment. But, when I am running jobs in the runner, it is giving me the below error -

MountVolume.SetUp failed for volume "gitlab-runner-devops-pvc-efs" : kubernetes.io/csi: mounter.SetupAt failed to check volume lifecycle mode: volume mode "Ephemeral" not supported by driver efs.csi.aws.com (only supports ["Persistent"])