You have perhaps encountered the iPadOS “Shelf” - this being a feature of the current iPadOS multitasking environment.
iPadOS permits you to have multiple App windows for the same App. The shelf, when triggered, shows a thumbnail of each running window of an App.
For example, for Mail, each draft or open email message will have its own self-contained window. Simply tapping a thumbnail will switch directly to that running message window. Each App - such as Mail, Safari, Notes, Calendar, etc. - has its own corresponding shelf.
Individual App windows can be closed directly from the Shelf; just swipe the unwanted thumbnail off the top of the screen. Note however, that Multitasking and associated Shelf functions cannot be disabled.
This article from Appleinsider has a useful explanation of this feature along with many of the updates to multitasking:
https://appleinsider.com/articles/21/08/12/how-to-master-multitasking-on-ipad-and-ipad-pro-in-ipados-15
The iPad User Guide is also a rich source of frequently overlooked information. The Guide is available both online using a web browser (such as Safari), or as an Apple Books download:
iPad User Guide - Apple Support
https://books.apple.com/book/id1567104892