Your dog is likely a terrier breed. Terrier breeds were created to go after orey, so their prey drive is not always controllable.
I can only recommend a to run a line across the yard and tie your dog to it so it has a lot of room to roam the yard without being able to get out.
It was likely not properly socialized as a pup. It will not improve.
I had a 35 Lb terrier/chow mix and her prey drive was incredible. One day I opened the back door of the garage. We had a huge back yard, downhill. She greeted me but at the next instant we both noticed a crow on the ground at the bottom of the pard. She took off. Crows take bit to get off the ground with those long wings. She snatched it right out of the air as it took off and dispatched it. Crow didn’t like it much, but still it was an incredible sight
When I was reading this, my thought was that this dog sounds like a terrier. I just recently lost my precious little Jack Russell Terrier. She got quite old & had the problems that got with it. The point is that she was always aggressive to other animals back when I took her for walks. I always restrained her & later she was pretty much restricted to indoors. I loved & miss that little dog, but she did have certain undesirable traits. A person getting a dog for the first time needs to be aware of some of this.