Hello, fellow programmers

I've been creating a todo program for myself where I can create tabs within tabs within tabs etc. But sometimes I feel like moving one of the tabs to another place, but not necessary the same JTabbedPane.
I've created a program visualizing what I mean with tabs within tabs.

SSCCE jar file
Java Code:
import javax.swing.GroupLayout;
import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.JTabbedPane;
import javax.swing.GroupLayout.Alignment;



public class Tabs extends JFrame {
	JPanel contentPane;
	Tab tabs;
	public Tabs(){
		contentPane = new JPanel();
		setSize(200,200);
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		setLocationRelativeTo(null);
		setContentPane(contentPane);
		tabs = new Tab();
		setLayout();
		setVisible(true);
	}
	
	private void setLayout(){
		GroupLayout layout = new GroupLayout(contentPane);
		contentPane.setLayout(layout);
		layout.setHorizontalGroup(
			layout.createParallelGroup(Alignment.LEADING)
				.addComponent(tabs, GroupLayout.DEFAULT_SIZE, 20, Short.MAX_VALUE)
		);
		layout.setVerticalGroup(
			layout.createParallelGroup(Alignment.LEADING)
					.addComponent(tabs,GroupLayout.DEFAULT_SIZE,20,Short.MAX_VALUE)
		);
	}
	
	public static void main(String[] args) {
		new Tabs();
	}

	private class Tab extends JPanel {
		public Tab(){
			JTabbedPane pane = new JTabbedPane();
			pane.add("Test",new Tab("Test"));
			pane.add("Code",new Tab("Code"));
			setLayout(pane);
			
		}
		
		public Tab(String name){
			JTabbedPane pane = new JTabbedPane();
			pane.add(name+"1",new JPanel());
			pane.add(name+"2",new JPanel());
			setLayout(pane);
		}
		
		private void setLayout(JTabbedPane tabs){
			GroupLayout layout = new GroupLayout(this);
			setLayout(layout);
			layout.setHorizontalGroup(
				layout.createParallelGroup(Alignment.LEADING)
					.addComponent(tabs, GroupLayout.DEFAULT_SIZE, 20, Short.MAX_VALUE)
			);
			layout.setVerticalGroup(
				layout.createParallelGroup(Alignment.LEADING)
						.addComponent(tabs,GroupLayout.DEFAULT_SIZE,20,Short.MAX_VALUE)
			);
		}
	}
}
What I want to do is being able to move for instance the Test1 tab to where the Code1 and Code2 tabs are. Or Move the Test1 tab to where the Test and Code tab are. (I could write an example on how I want it to look after I've moved the tabs if you want)

How could this be possible?
Know a forum thread that has taken up this problem before? (I couldn't find one)

Thanks for spending your precious time on me