You can use a preinstalled JDK instead of the default version for the installation by using the ––javahome option. Communications Server, by default, uses the JDK version from as-install/jdk.
The AS_JAVA variable in the asenv.conf file always points to as-install/jdk. If you want to use a different JDK version, update the asenv.conf file manually and changed the value of AS_JAVA.