Because in times of uncertainty many investors buy gold to protect themselves, even though its price can also fall.
Gold pays no dividends or interest. Its price is sensitive to real interest rates and the dollar. It can fall for a long time, so it is not a risk-free vault.
In times of fear, gold sometimes rises while stocks fall, but not always.
Compare gold with rates and the dollar to understand its moves.
Believing gold can never lose.
Safe haven does not mean risk-free.
Related mission : Gold: safe haven and real rates
Practise on Doji Academy