On the mechanism of CO and CO2 methanation over Ru/molecular-sieve catalyst