A custom theme with support for multiple layouts

As per my understanding of what you need, you want to create page templates. Page templates are a specific type of template file that can be applied to a specific page or groups of pages, you can apply a custom design to different page templates as per your requirement.

You can read more about page templates here:
https://developer.wordpress.org/themes/template-files-section/page-template-files/
https://www.wpbeginner.com/wp-themes/how-to-create-a-custom-page-in-wordpress/