Seems your Proximity Sensor is not locking your screen during calls? Make sure nothing is blocking the sensor, it is located at front top of iPhone just above the earpiece speaker port. Make sure no screen protector or case is blocking it. If still problem, try Restore of iPhone with iTunes 10.7 or 11 on computer. If still problem and there is Warranty or AppleCare make Genius reservation and take to Apple for resolution.