But you're not locked in with the vast majority of CDs, you can usually redeem them by giving up some interest.
For example, if Alex bought $10,000 of VBTLX (The total bond market fund) a year ago today for $10.83 per share, he would have gotten about $220 in distributions and it would be worth about $9,612 for a net loss of about $168 (ignoring taxes, ER, etc.)
If Bob bought a 5 year CD for $10,000 from Ally bank a year ago at 1% interest (I don't know what rates were then, but I doubt they were that low) and sees that the rates are now 2.5%, he can break the CD for a 5 month penalty and has $10,058 to put in the new CD (again ignoring taxes).
This is just one particular case, but if there is some situation where a bond fund has less interest rate risk than a normal CD I'd be interested in hearing about it.