most of the tag along bikes/bike attachments for kids seem to attach to the seatpost. But some attach to a rack.
I belong to a FB buy nothing group and people give these away fairly often. Although it might not be easy to find a rack mount one
It would help if you posted a picture of the bike.