Absolutely right! No laws have been broken, the contract under which the ebike was purchased seems to have been valid (there was clearly an offer, and acceptance of that offer and the exchange of a consideration), and, as with any other purchase caveat emptor applies.
The purchaser is responsible for determining whether or not what they are buying fits the purpose they have in mind for it. If they didn't check whether it could be legally ridden on the road as a bicycle before they purchased it, then they have only themselves to blame. They cannot, in law, take action against the seller, unless the ebike in question was new and was sold with a misleading description, which doesn't seem to be the case here. For second hand goods the seller is under no obligation to give an accurate description of the legality of the goods being sold, and even if he/she does then it doesn't mean much, as they probably would not be considered, in law, to be competent to give such an opinion.