Reactor for thermochemical CO2 reduction