Second, it is a unit of account, or a standard unit for quoting prices. Third, it is a store of value, a means to store wealth from one time period to the next. You can put your money under your mattress and it will be there next month. Lots of things can be used as money. In much of our history, we used gold and silver.
Some places use rocks to trade goods.
During wars, cigarettes and chocolates are often used. As long as the commodity serves the three purposes described above, it can be money. In today's world, we use fiat money, or paper money. The money is inherently worthless except for the purchasing power that we trust it will bring. Without trust, the paper money becomes useless pieces of paper.