Many Scrum Teams think they should move the undone Product Backlog items at the end of the Sprint directly to the next Sprint, but this is not true.
Imagine something more important emerges in the current Sprint. So, naturally, you should work on it first in the next Sprint, not on the undone PBIs spilled over from the previous Sprint.
Scrum Guide says: If a Product Backlog item does not meet the Definition of Done, it cannot be released or even presented at the Sprint Review. Instead, it returns to the Product Backlog for future consideration.
So, when you return the undone PBI to the Product Backlog, you give them a new opportunity to be ordered again. If it stays on top of the Product Backlog, naturally, it will be selected for the new Sprint.
Otherwise, you need to change your focus and put it on the more important PBIs based on the latest ordering of the Product Backlog.
-----------------------------------------------------
If you want to start your Scrum journey powerfully and learn Scrum through a high-quality training with several priceless bonuses, attend my upcoming Professional Scrum Master (PSM) class. Click here to get more information about the class.