In brief
git revert creates a new commit reversing an earlier change. The old commit remains in history rather than being erased.
Useful to know
git revert creates a new commit reversing an earlier change. The old commit remains in history rather than being erased. [1]
This differs from moving a branch backwards with reset. Later dependent changes can require conflict resolution and testing. Reverting code is itself a new change and needs an understandable resulting behaviour.
Sources
For further detail and to check the information: