Yes, in theory you could do that, but the efficiency depends on the temperature difference. The higher a temperature difference you have, the better. The theoretical maximum efficiency of a heat engine is (Tmax-Tmin)/Tmax (temperature in Kelvin). So a few degrees is not going to result in anything usable. So to reclaim the energy, we need a large temperature difference.
But since the goal is to cool the datacenter, we want the temperature difference to be as small as possible.
Reclaiming energy from waste heat usually only pays off in industrial settings. If you have very hot steam, you can use it to power a steam turbine and generate electricity. But at lower temperatures, the efficiency is too low.