The Aztecs had admirable agriculture technics. For example, they used chinampas. Chinampas is a method of farming that used small, rectangular, spaces to grow crops on shallow lake beds in the Mexican valley.
They were basically man-made islands as you can see in the picture above. These "islands" provided rich soil and it gave easy access to water. Furthermore, the Aztecs practiced the art of terracing. It provided more land to grow crops. They look like steps on a hillside.
They usually grew corn because it could be stored for long periods of time and it could be turned into flour. Squash was another staple. They also grew beans, avocadoes, tomatoes, and guavas.