Of course you could. The old bed warmers that they put hot coals in were made of metal
It would have some drawbacks however:
- Compared to metals, the temperature of the water in the hot water bottle is limited to a comparatively safe range by the physical properties of water, it will boil off at 212 °F./100 °C. On the other hand you can get metals white hot- enough to burn right through the material of your bed - and they will still be solid.
- Water has a higher heat capacity than metals per unit mass and per unit volume so it can supply more heat without having to start out as hot as the metal would have to in order to supply the same amount of heat.
- Because it has a higher heat capacity it would also take less water to warm the bed than metal.
- An empty hot water bottle is easier to store than a chunk of metal - and a lot cheaper.