How are lending rates determined?

How are lending rates determined?

Each security has its own lending rate based on demand.