

Authors receive 25% of the ebook sale to a library in the US. Frequent lends will also influence future purchases made by the library.
https://janefriedman.com/what-do-authors-earn-from-digital-lending-at-libraries/
Libraries in Canada and the UK pay royalties for each lend.
https://societyofauthors.org/where-we-stand/public-lending-right-plr/
It shouldn’t. The DRM is on the Amazon book file format. The books I get from my library are usually epub format.