Many ways can help improve at chess, but most players tend to prefer studying openings. It is the easiest way indeed: the exact moves you prepare at home are likely to happen in one of your future games.
With middlegames, it is more complicated. It is impossible to predict exactly what positions you will have on the board in your future games. You can’t memorize middlegames. You have to understand them.