Probably easier if I describe the approach.
Firstly, you need to use a Custom Form. A good description of what that is is given below:
I would recommend creating a single row table (Helper Table) to use to drive the form. All columns in the helper table should be user specific. The key point is that you need an action that first sets a unique value in a column in the helper table as the form is opened. This value is used as a UUID for both the parent record as well as the child records.
Your custom form serves the purpose of both creating the parent record and adding N child records in the same screen. You need to use visibility conditions to show either the parent record entry inputs, or the child record inputs. This can be conditional on the state of a relation between the UUID and the child records table. That is, if the relation is empty then show the parent record inputs. Once the parent record is created, the relation will no longer be empty and so you switch to the child record creation inputs. You can dynamically show the added child records using a collection component with the aforementioned relation as a source.
That’s essentially the guts of it. Obviously there is a bit more to it than that, and there will be specific details related to the exact user experience that you want to achieve.