Are the files for the books on the Mac? Also, if you open the Books app, do any books show? If you bought books from Apple, they should show, even if they are not actually ON your Mac. They will show with a little cloud and down arrow indicating they can be downloaded. When on your Mac, the cloud is not there. So you can get the books back from Apple, if that is where you got them. If you opened in in iTunes from other sources, you can get them from this sources and add them in Books. Once in Books on the Mac, you can sync to the iPad.
One other thought is that if you have a backup of the iPad with the books in it, you could restore the iPad, then install iMazing, do a backup using iMazing, then get to the books in iMazing to get them back to the Mac. Lots of steps, but should work.