An exact answer will depend on which user interface you're using.
If you're using the Modern User Interface, this might be of some help:
!define MUI_DIRECTORYPAGE_VARIABLE $InstallDirectory
!insertmacro MUI_PAGE_DIRECTORY
!define MUI_DIRECTORYPAGE_VARIABLE $JRE_InstallDirectory
!define MUI_PAGE_HEADER_TEXT "Choose JRE Location"
!define MUI_PAGE_HEADER_SUBTEXT "Choose an installation path for the JRE."
!define MUI_DIRECTORYPAGE_TEXT_TOP "This program will install the JRE to the following directory. To use a different path, click Browse and select another directory. Click Next to continue."
!define MUI_DIRECTORYPAGE_TEXT_DESTINATION "JRE Path"
!insertmacro MUI_PAGE_DIRECTORY
That will display the standard Directory page with all the default text (asking for the installation path of your program) and store it in the $InstallDirectory variable.
The following page will have the same layout but with custom text to ask for the JRE install directory, which will be stored in the $JRE_InstallDirectory variable. For more information, see the documentation.