The generator output will be marked on the panel. If it is unclear or covered with paint, you can confirm it as follows:
Turn on the generator and adjust it. the generator Speed and voltage reach the nominal value.
Assume the generator's rated voltage is 380 V.
Set the multimeter to the maximum AC voltage setting and measure two of the four segment terminals as desired. When the measured value is 380V (maybe close to 400V), these two terminals should be line voltage terminals and should be marked. Then, always use the method above to find the third line voltage terminal.
The remainder is the neutral terminal, which must be grounded in the earth's electrical network.
It is estimated that your generator will not be connected to the network, so it is not necessary to identify the phase order of the three voltage terminals dth line.