Scanner leaving lines in scanned document
If the documents you're scanning start to display a line or multiple lines down the length of the page it is usually the sign that the glass bed is dirty and needs cleaning. The lines can be coloured or simply just black.
An example of lines being left on a scanned document. These lines can also be black in colour
To ensure it's not an issue with the scanner itself, try scanning the same document on the large glass bed, a single page is enough to get the information we need. If the page comes through clean, it's just the thin side that needs cleaning.
If the page comes back with the same issue with the exact lines in the same spots then it's most likely a printer hardware issue though this is unlikely to occur.
Wipe down the glass bed, especially the thin strip of glass to the left
If the scan from the glass bed came back clean, simply open the lid to expose the glass bed. Then with a cloth, wipe down the glass bed, especially the left side with the thin glass strip. This is the side where the pages from the feeder up top will pass through to complete the scan. Wipe the top part of the lid as well just to be sure.
Once clean, try scanning the document again and it should come through clean and without issues.
If you do still have lines, double check you cleaned the strip properly. You can even print out the scanned version and use the lines on the page to match up where on the glass strip the speck of dirt/dust is.