Could testosterone pills make my gynecomastia go away and make me gain muscle?

No. Testosterone pills will make your gynecomastia worse. You'll possibly develop an imbalance between testosterone and estrogen, and your breast tissue could enlarge.
No and yes. It may not make your gynecomastia away, and it will be easier to build muscle, but your balls will grow smaller and you will have increased risk of prostate issues.