The gradlew command specifically uses the version of Gradle that’s configured for the project. This is generally the preferred method as it makes sure that you don’t have to manually install many different versions and know which projects are compatible with which versions. The project in question is likely not compatible with Java 11.