There are two reasons.
First: Sit-ups are short-lived and will bring you a long platform period. And once you don't insist (which is very easy to happen), its rebound is very powerful.
Second: Sit-ups before going to bed will affect rest. Not only that, all strenuous exercise will affect sleep. So don't do it.
If you want to have exercise time before going to bed, it is recommended to finish it half an hour before going to bed. This can adjust the body and recover better.
In fact, running, skipping and swimming are all good ways to exercise the whole body. Don't deliberately grab a place to exercise, otherwise it will be counterproductive.