you just need to add the version number while calculating the phrase.
it should be very simple. But how?
How exactly do I need to change 'this code to get a new kind of seeds?
BIP39 seeds don't
have a version number, so you shouldn't be trying to generate both kinds of phrases in the same class/method.
The first "nibble" (groups of 4 bits) of an Electrum version, plus 2, tells you how many nibbles are in the version hex.
i.e. 0x01 version is (0+2) nibbles long = 8 bits,
and 0x100 version is (1+2) nibbles long = 12 bits (same as 0x101).