Plagiarism is useless. Generally, university libraries have staff in the credit card area at the entrance. After registration, they pay a deposit, and some libraries give it in. As for whether the deposit can be refunded, I don't know.
Some libraries do not allow students who are not from their own universities to enter, and the cards will be very strict.