If your air rifle is a "springer" (a.k.a. "breakbarrel"), then these take some getting used to to shoot accurately. And each air rifle is different. You have to learn how to hold the rifle gently (no tight gripping) and also to hold it where it wants to be held. Usually, you will find the rifle likes your support hand back further than you're used to for a firearm (back = closer to the trigger guard). The rifle lays in your hands, you don't grip it. Let it move when you shoot it, don't try to force it to do what you want it to do.

Shooting a springer air rifle is much more difficult to master than shooting a firearm. Just because you can shoot a firearm does not mean that you can shoot a springer. But if you can shoot a springer accurately, you will be a real sniper with a firearm!