Aperture and shutter speed work together to correctly expose an image, they work like a sea-saw whilst one goes up the other must go down. First of all you must understand what each thing is.
Aperture is simply the size of the hole that lets light in to your camera, the bigger the hole the more light you camera can take in.
The aperture is measured on a scale of F-Stops, the lower the number = the larger the aperture (aka the large the whole) As you can see in the diagram above.
The aperture is very important in determining focus in your image, you may have seen those images where one thing is focused and the rest of the image is blurry aperture is what creates this.
Depth of field is the term used to describe the level of focus your image has. If you have a picture where only a small section is in focus you are said to have a “shallow depth of field”
If you imagine you were taking a photograph across a room, with a very small aperture the area of focus would be very large as in the area that you could focus on would be large.
Whereas photographing the same room with a large aperture would mean the area of focus would be very narrow or shallow. This is all due to the concentration of the light that comes through the lens to the cameras sensor or film.
Here are some examples of how this works
With a smaller aperture the more of the composition is focused allowing you to see more detail within the entire image. Whereas with the larger aperture the details you see are limited by the focus.