when a game is released on older consoles and newer consoles at the same time, do they still use the same engines and models for each system but with just higher resolution? or do they make two versions of the game?

also how much needs to be changed when say creating a game to be run on both microsoft and sony platforms?