If the amniocentesis shows lung problems. Can this be reversed?

Yes. The amniocentesis will generally show if the baby's lungs are mature yet or not. Given enough time all baby's will have mature lungs.
There are things. That can be done . Is the lung issue due to premature fetus . In that case there are medicines that can be given to make the lung mature including steroids . Good luck.