Muskrats are pretty agressive so care should be taken when dealing with them. You can use humane traps similar to those used for raccoons to catch them and release them elsewhere. Or you can use snap traps to trap their legs which will kill them eventually.
If you want to trap the muskrats alive, you can go for "muskrat baits"(available in markets and the rats like them). Place one to two teaspoons of the bait on the trip pan and entrance of the trap sets. After hunting, displace the rodents some 10-15 miles away.
An overabundant muskrat population and the resulting excess burrowing, garden eating, and scent can become a nuisance. A repellant can be purchased to discourage the pests from eating plants, and live-traps, body-grip, and leg-hold traps filled with muskrat bait are all effective methods of control.