Problem and Solutions
Is it possible to run Java16 code on Android ?
By M.K. Verma · 4 May 2022

You can't use the Jave 16.
The last version is 11, you check this. https://developer.android.com/studio/releases/gradle-plugin?utm_source=android-studio-2020-3-1&utm_medium=studio-assistant-stable#java-11