It's not clear from your description exactly where the corrosion appeared; was it on the phone or on the display? Either way it's concerning as there should never be any corrosion inside a phone, but if it's on the screen then I would strongly suggest your next step should be to replace the screen.
Fortunately your phone is one of the last ones Apple made that doesn't have the screen paired to the motherboard so you can replace it without getting a warning that the screen might not be genuine - even if it is. You will, however, lose your True Tone function unless a small piece of data called the MtSN is copied from the old screen to the replacement. Any phone repair store should be able to do that, and it will get copied as part of the system configuration if you use Apple's self repair program. You can buy a programmer yourself, but even I would hesitate to spend around $85 USD for something you might only ever use once.
If possible you might add pictures of the corrosion to your question; there are some very experienced repair technicians on this site that might be able to tell if it's a problem or not. If the corrosion is on the motherboard that would be extremely concerning and may require board level repairs that would be beyond the ability of most of us home DIYers.
[guide|21499|Adding images to an existing question - iFixit Repair Guide]