Multi-access edge computing (MEC) as an emerging technology which provides cloud service in the edge of multi-radio access networks aims to reduce the service latency experienced by end devices. When individual MEC systems do not have adequate resource capacity to fulfill service requests, forming MEC federations for resource sharing could provide economic incentive to MEC operators. To this end, we need to maximize social welfare in each federation, which involves efficient federation structure generations, federation profit maximization by resource provisioning configuration, and fair profit distribution among participants. We model the problem as a coalition game with difference from prior work in the assumption of latency and locality constraints and also in the consideration of various service policies/demand preferences. Simulation results show that the proposed approach always increases profits. If local requests are served with local resource with priority, federation improves profits without sacrificing request acceptance rates.