It’s not as volatile, as the stock market, but bonds are still traded the same way and are still risky in certain cases.
Just as an example, Silicon Valley bank failed because they were invested heavily into bonds because they’re “safe” and when the Fed changed rates, they couldn’t liquidate their bonds quick enough to pay out their obligations because nobody wanted to buy the lower interest bonds they held when newer bonds were higher interest.
You can end up in cases where a pension fund can’t liquidate their bonds to make regular payouts during times like now when the Fed is increasing rates to combat inflation.
All investments are risky. With a pension, you’re trusting a company you work for to manage that risk for you in exchange for it being all or nothing based on if you stay there long enough.
With a 401k, you can manage your own risk level yourself. If you want to put it all into bonds, you can do that.