Bitcoin has value because it can function as a store of value and a unit of exchange. It also demonstrates six key attributes that enable its use in an economy. The definition of value in a currency has changed over centuries from physical attributes to the velocity of its use in an economy.
Bitcoin demonstrates the attributes of a currency, but its primary source of value lies in its restricted supply and increasing demand
Well explained, I was going to give the same explanation when I saw the topic title, but you have already explained it all. The value of something is judged or compared with the value of another thing. Like before people exchanged services and products, they gave rice, wheat, etc. to get the service or product in exchange for another person. How much rice and how much wheat is to be given, is calculated. This is known as the bartering system. If the product is rare, or if polluted then the rates are different, many people ask for less and many ask for more. But this procedure was too old.
Currency came into place a long time ago, as before people used gold, silver, and iron as currency, then coins, now notes, and now digital money. who knows what comes next? Well, the point is everything has value in it, due to demand, and supply, if the supply is lesser and demand is higher and people agree to give more then the market value then time by time as demand increases the value of the asset or currency also increases. But currency don't have scarcity factor in it, that's why it have inflation issues, while BTC have scarcity factor in it, thus its considered as a hedge against inflation.