This site has good instructions for setting up the `PATH` variable: https://www.java.com/en/download/help/path.xml
Alternatively just change the [build command](https://www.geany.org/manual/current/index.html#build-menu) so that the command has the full path to the compiler/interpreter executable (ex. `C:\Program Files\YourLanguage\whatever.exe` instead of just `whatever.exe`).