Yes and no.
Yes, I have used the Scarborough to Whitby track.
No, it would not be suitable for a 20" folder.
That is partly dependent on the weather, but stretches of the track are badly rutted.
Lots of complaints locally about it, so something may have been done since I was on it.
Also dependent on your bike handling skills.
Mine are not that good, so I ended up pushing for stretches.
If you do a round trip, bear in mind it's mostly downhill from Whitby to Scarborough.
You will need a lot more battery capacity for the other direction.
Nice, former station style tea room at the Scarborough end.