IANAL but I think they can only do that if you've bought those shares on margin. They _may_ still be able to loan out shares you've 100% paid for unless you explicitly tell them not to.
Denying RH the ability to loan out shares was a tactic discussed on WSB
They can loan your shares out whether they are bought with cash or margin. Some brokerages allow you to opt of loaning your shares to short sellers. Robinhood pays you part of the interest made if they lend your shares out, but as far as I know there is no way to opt-out of share lending on Robinhood.
Denying RH the ability to loan out shares was a tactic discussed on WSB