Phase correction using programmable phase modulator (PPM) in optical coherence tomography