Each Node has set of logical functions though all these logical nodes such as MME, SGW and PGW can reside in the same hardware. Going forward major changes are going to happen as part of 5G network development (SDN and NFV). There might be many reasons to have SGW in the network, few of them I would like to write down here.
MME takes care of mobility related functions, authentication of subscribers while PGW takes care of providing data end point towards external world and IP address allocation and charging related stuff. SGW is the node which reduces the mobility signalling between MME and PGW but putting SGW in between. If SGW is not deployed in between MME and PGW then during each handover signalling messages will go to till PGW. Since PGW is one of the complex nodes in the network which performs various operation related to data if each time handover signaling with go to till PGW, it may impact PGW performance.
With the separate nodes SGW, network loads will be distributed and PGW does not need to participate for each handover signalling messages.
Another reason when UE roams into visited network then SGW is the node which generates charging records of usage of network resources did by UEs belong to other network.
EPC is a box is a solution which provides LTE network services for users where mobility procedures are less likely to happen. For example: LTE network in a box solution can be used in rescue operations, battle fields, Enterprise network and public safety.