What was the purpose for money being created? I assume goods and services were traded before its creation so I'm wondering why there was a need for it. Was it to do with debts, like how bank notes were created?
I assume you are referring to the invention of coinage. There were many benefits to the use of money, such as early coins, that made it the natural step from bartering. If one wants to barter, they need to have something to barter, then find someone else whom actually wants said item and hope they also have something you want, and then arrange to bring both items to each-other and trade.
Money is something that everybody wants, it is a universal currency. Everybody wants it, and so you can buy anything with it. As well, money is much easier to transport.
Money also allows for the buyer and seller to easily know the right price. No longer does one need to calculate if twenty bushels of hay is worth 3 chickens and a bowl of mushrooms, or 2 chickens, a basket of berries, and grandma’s pecan pie. Now things have a set price, because they will always be bartered for money. Twenty bushels of hay is now worth 3 gold coins. 4 if its winter. Simple and easy.
And if your money becomes worthless, it is still quite literally worth its weight in gold (or silver, or bronze, or whatever your currency was made of), and can be melted down and resold. Eventually with the added infrastructure of modern times, we have switched to a kore merit based currency, the bill/note, which is essentially an iou backed by the government. Everybody wants it, so it has value, but without our infrastructure out current currency is essentially worthless.