Do you mean the chain rings (front gears) or the freewheel cassette (rear gears)? The chain rings are pretty straightforward
For the rear cassette, you'll need some specialized tools, but they're not expensive. Once again, Park Tools has a good tutorial. I'm not affiliated with Park, but do own some of their products. They make very high-quality stuff and price it accordingly. If you're only doing the job once, you can find cheaper versions of the same tools.
Drive train parts tend to be torqued on pretty tightly. Don't be afraid to apply some force to them, but do it carefully. Make sure the wrenches are seated firmly in place, and then jerk repeatedly on them to break things loose. Re-seat the wrenches if they start to drift free. It's the same principle as an impact wrench, but with muscle power instead of pneumatics.
What brand is your rear hub? You will need to know that for both the proper tool and to get the replacement gears. With an 18 speed I would assume you have a 6-speed rear sprocket. I like Alan don't work for Park but I have been using their tools for over 20 years to work on my own & friend's bikes. You will need to determine the freewheel brand you have and then select the proper freewheel removal tool, most of the freewheel removal tools can be found for around $10-$15 but you must use the correct one or it's really easy to do some damage. You will probably need a chain whip as well to complete the job. If you haven't done much bike maintenance and want to learn, that's a good project to start. I have read a lot of books out there on bike repair but the best I have seen is the Park BBB-2 "BIG BLUE BOOK of Bicycle Repair", it has really good pictures and explanations for just about anything you would want to do as well as it shows you how the tools work.