#XP is not just for combat
XP is not just for combat
You're the GM, you can give them XPs for any reason you want, not just resolving combat.
e.g. using their skills, using their wits, using their charm, good role-playing, progressing the plot, coming up with good ideas. Even trying something and failing should arguably be XP awardable (since you learn from failure, in some cases more than from success). (I used to give XPs just for showing up, but that's just my own thing)
Any of the above can be used to award XPs should they make friends with the goblins instead of fighting with them.
But the bigger issue is:
changing events too far from the module will cause errors in continuity, that will force me to improvise too much for my first game
Well that's one of the jobs of the GM!
Luckily you've recognised this possibility in advance. So just prepare some substitutes for any plot points that required the goblins to be dead which somehow get the plot back to "the book". Maybe make the goblins' survival part of it, to avoid the players feeling railroaded.
(e.g. the PCs find themselves stuck now because they didn't kill the goblins, but then maybe some of the goblins come and help them out of it and get them back on track)