No thats what you did... Money in a bank only gains interest through loans... 100% of the money it gains id by creating debt, full stop.
Inflation creates money by encouraging investment, while that benefits debtors, it also benefits anyone investing without going into debt as well, therefore it benefits all investors and not just those in debt. Full stop.