What you want is Split VIew & Slide Over which can be enabled per Open two apps in Split View on iPad - Apple Support .
Once that is done, you open your first application and/or document. Let's say you launch Pages and choose a document. At the very top of the screen, you will see ⋯ and click those. Select Split View. Your open Pages document now scurries to the left edge of your screen. You now launch Pages again and select another document. Now you have two open Pages documents side-by-side on your screen. Each instance has that ⋯ symbol at the top of it which also has a close option on it to dismiss the respective document Split View member. To edit either or both, you will need to tap that edit icon on the respective open document toolbar.
Instead of two Pages applications, one might choose Pages and the other App could be Numbers though the latter might be limited in a Split View display.
Tested: Pages v14.3, iPadOS 18.2 on an M4 iPad Pro in Landscape orientation.