I am out of spaces in my main 200amp service panel.

I have a double pole 40 amp breaker that is available (or I can change it). 5(3 subpanel is 33 feet away indoors. I will need 5 poles (spaces) in subpanel, and the total amps used from all items will be 39/22. I am Using 12/2 to go to all outlets from subpanel.

What wire should I be using from main panel to subpanel?

Do I need a ground rod at the subpanel?