It's using flexible sections
You are right, I have found that I can add 'main' sections, but flexible sections format also allows for subsections. This is where the error occurs.
So right now in just this specific course:
1. You can only add main sections (at the bottom)
2. You can not add subsections
3. You can not move sections
What puzzles me is that mdl_course_format holds the information for sections and subsections. I see some sections having the value 'parent = 0'
This is not possible: section 0 does not allow for subsections.
I altered this in the database
to f.e. parent = 10, but it doesn't change anything (or crashes the course)