@DPittman is an agronomist. He might have better info than I do. Basically, plants have needs just like machines. Routine maintenance will make them happy and you in return.
Each kind of plant needs its own schedule of routine maintenance. Most plants are different from other plants. Each kind of plant needs the right food in the right quantities, water in the right quantities and schedule, the right pH and soil qualities, the right amount of sunlight, the right humidity and air temperature levels, and tight control of predators and competition.
Seeds also need to be planted in a way that encourages germination. The right depth, the right soil conditions, the right time of year.
The best success will happen when you choose the right plants for your conditions. Look around your neighbourhood and see what plants grow well in many yards like yours. Not just one yard.
Gardeners are like machinists. Most love to share their knowledge and will help you get going.
If that approach doesn't work, you probably have soil contamination. If so, you might be able to fix it, but it's easier to just remove the dirt you have and replace it with good soil.
I'd be particularly concerned about your courtyard. Not much sunlight there. You might need plants that don't need much sunlight.