Answer:
B. If you come here when the moon is full, the legend goes you can see the ghost of an old sailor walking along the shore.
Step-by-step explanation:
B is the correct answer, because the comma is basically directly there to add a pause to the sentence, between the cause and the effect.