I have the following sample data frame:

```
import pandas as pd
array = {'name': ['John', 'Rob', 'Rob', 'John'], 'color': ['Green', 'Black', 'Blue', 'Black']}
df = pd.DataFrame(array)
df

```

It looks like this:

```
    name    color
0   John    Green
1   Rob     Black
2   Rob     Blue
3   John    Black

```

I am looking for a way to create three separate tables or data frames:

Main:

```
    name    color
0    1       1
1    2       2
2    2       3
3    1       2

```

Names:

```
        name
   1    John
   2    Rob

```

Colors:

```
        color
   1    Green
   2    Black
   3    Blue

```