NASA's Planetary Defense Systems On Close-Approach Asteroid

I have always been wondering, is there a way we could deflect meteors or asteroids? if YES why haven't we tried yet? Well, maybe there's but currently NASA is on its way to test out its planetary defense systems on an Asteroid TC4 which will come extremely close with earth on October 12 at an estimated distance of 31,000 miles
Paul Chodas, who is working as a manager of the Center for Near-Earth Object Studies at NASA’s Jet Propulsion Laboratory, told Newsweek what they have a plan to protect Earth from asteroids in the future if not today.
"It’s fairly rare to find an asteroid coming this close five years ahead of time. We knew it was coming so we could prepare our exercise months ahead. We didn’t know exactly how close, but knew it was likely to be within one lunar distance. It was a perfect example"
Animation depicts the safe flyby of asteroid called 2012 TC4.NASA/JPL-CALTECH
NASA's prime activity is to track the orbit of the asteroid as shown above which they have been doing since august when they first spotted it. They already have a rough idea of its size from its brightness in optical wavelengths.But studies shows that dark asteroids are known to have low densities, and bright asteroids are known to have higher densities.In order to tell how much energy can an asteroid deposit they first need to know its size and its most importantly, its mass
If they had 10 years of warning time before the impact, NASA agrees that they can try to deflect it depending on its size. There are several ways to be used to deflect an asteroid from its course or destroying it. The simplest will be to cause a collision with a massive spacecraft at high velocity.
Another is what the CNEOS call a gravity tractor, which is for a more bigger asteroids. This would involve picking up another rock and hovering it over the asteroid by which the mutual gravitational attraction over a year or two might be enough to change the velocity.
Last but not least is through firing an ion beam directly to the asteroid at high velocity again that should be able to move an asteroid from its orbit.