Read this thread linked below.Mine just started with this issue. My daughter's 2018 did this and after several trips to dealers she traded it for a 2019 which was supposed to not have the problem. Her 2019 is now doing it and my 2019 at 51K just started doing it. Just found this video and I say it is worth a try.
gmc acadia shift to park fix - Bing video
Tested working, 2017 shift to park fix.
It contains all the info about the cause of the issue and how to fix it or even just bypass it.
The micro switch that causes the issue is over stressed but can be replaced if you are a bit handy.
Take the time to read it all and learn instead of looking for some "quick fix".