In my country, the only legal way to sell a gold bar is to sell it to the central bank. What are the reasons why some countries hoard gold bars?
Gold does not depreciate. It does not oxidate. It keeps well. Its an asset that has a stable value. There is currently no other like it.
Think of the following. Imagine the world suffers a major disaster. Chaos emerges. Rule of law collapses. The monetary system as we know it is destroyed. We could either go back to barter (and surely some will do). Or we can go back to a hard currency, like those in the past, where money was basically in the form of gold coins (and other metals). Thus, gold is, in that sense, THE SAFEST asset, because it will provide you with purchasing power in the case of a major civilisation collapse (and anything in between that and a mere currency crisis). Every kingdom on earth sought to increase their gold reserves (called mercantilism).
But this begs the question, so why gold and not for instance water (which is way more useful for life)? The answer is built upon several factors. One is that gold depreciates quite slowly (paper money however could be lost in a fire). Second, it is easily storable and hard to steal on masse (unlike water). Third, is highly regarder by the rich and powerful (e.g. kings). But the most important reason is sociological. It's a selfulfilling property of gold. It is regarded by other people as the safest asset and therefore it becomes the safest asset.
The answer from the former Chair of the Federal Reserve is in a word: tradition.
Gold is regarded as safe haven. It was used as an exchange before money was invented. Good hedge in crisis times.