Hello dominika151,
It sounds like Screen Time is still reporting information for the Settings app even after you restart the device and while you are sleep. If that is the case, then it is possible that the app is running in the background. To stop it from running in the background, you can complete the steps below that are also listed here: Close an app on your iPhone or iPod touch - Apple Support
iPhone X and later
1. From the Home Screen, swipe up from the bottom of the screen and pause in the middle of the screen.
2. Swipe right or left to find the app that you want to close.
3. Swipe up on the app's preview to close the app.
Also, you should be able to see more details on when the app is mostly used by checking your report information using the information here: Use Screen Time on your iPhone, iPad, or iPod touch - Apple Support
Best regards