In this presentation, we will focus on problems related to the magnetic confinement of a plasma in the context of the design of a stellarator nuclear fusion reactor. We will start by presenting the physical context and the underlying industrial motivations, then we will look at a modeling problem related to magnetic forces. After that, we will present theoretical and numerical results on a shape optimization problem related to the optimal design of coils. If time permits, we will finally consider the existence problem of optimal shapes for this kind of problems under a uniform reach constraint.