The function is called Flapperons
You need a radio that supports it and a receiver with an extra channel so that each aileron has its own servo that is plugged into a unique channel. Then you enable the mixing and the ailerons lower as flaps but still work as ailerons.