Julian "i want to let the creator of the Activity to change the amount of Text Input Fields"
I suppose you mean you want to let the creator change the number of Text input fields (not the amount of text in those fields).
I suggest you look at the way the Quiz settings form deals with adding x Feedback fields to the form. That's file moodle/mod/quiz/mod_form.php. It uses $this->repeat_elements(...).