Why do banks take deposits?

If banks do not lend savers' money, why do they take deposits?