I have done a lot of research with peacock and peafowl before getting one, here is my plan:
i have a shed where my duck can sleep every night that is about 6 ft tall, add a board high enough so the peacock can perch
i then built a fence outside the shed about 10ft x10ft, for both ducks and peafowl to get used to the surroundings
after a week or so, let the peacock free range, they will eventually come back usually at night to get fed.
i got my ducks before my peafowl so they can establish a place for them in the shed, because peafowl can get aggressive
i hope my plan to combine different fowl can help you with yours, i am making both duck and peafowl free range to clean up the yard and swim in the pond
they will be fine, they usually will leave each other alone or give space when one demands it