Journal Entry : Cost Center Main - B does not belong to Company Demo Company

I have created Salary Slips via Payment Entry, on selecting Make Bank Entry, journal entries are created as draft while submitting I am getting following error.
Demo Company - DC

In Company Settings, Main - DC has been set as Default cost center. No Parent Company.

Journal Entry ACC-JV-2022-00007: Cost Center Main - B does not belong to Company Demo Company

I am new to ERPNEXT, so I created 2 companies one is actual and another for demo purpose. Before migrating all the data in to actual company and I am using Demo company to ensure that everything is on track.

Kindly help me out what I am doing wrong? Cross checked all the salary components, Mode of Payments that anywhere Cost center Main B is selected.