A size limit is probably one useful thing the railways could do, as it seems the dodgy motorbike battery fires are worse than the early mobile device battery fires partly because the batteries are so much bigger.
Another would be to require some certification sticker or other. Yes, someone can put a fake sticker on something, but the penalty for fraud by deception is probably greater than the penalty for a luggage offence, so I don't know if many would bother.
Size of a fire is mainly about battery size and charge. My ideal solution would be for staff to have a floppy string bag or cowl and if they reckon they could pretty much envelope a battery (on or off the bike) it's small enough to travel. Banning non-folding e-bikes isn't a bad compromise (even if it clobbers my bikes).
A sticker is already present, batteries are labelled with capacity but it's impractical to use and doesn't account for physical condition.
But the biggest issue with certification is that it would make some organisation the gatekeeper to a £300M market, a position ripe for abuse, and already there's intensive lobbying for this with proposals that in practice would undermine battery safety.
I wonder what the actual data on e-bike safety is: what evidence based risk analysis are the train operators using to justify a ban?
Given that these fires can be so severe it's as well they're not waiting: 787s were grounded worldwide because of two battery fires.