You can convert a subtask into a task, i.e., if you need to delete the parent task but keep the subtask.
Drag and drop from List view:
From List view, open the parent task where the subtask is located.
Click and drag the subtask above or below its parent task until you see a blue line indicating the task's proposed position.
Release your mouse.
Detach a subtask from a task:
Open your subtask in Task view.
Click the + icon underneath the subtask's name to add it to a folder, project, or space.
Type the name of the location where the subtask should be a task and then select its name when it appears in the drop-down list.
Right-click your subtask in List view.
Select Detach from the drop-down menu that appears.
Your subtask is now a regular task in the folder, project, or space you added it to.
If you don't add your subtask to a folder, project, or space before detaching it, your subtask becomes a regular task in the Shared with me section.