Insight into interface behavior and microscopic switching mechanism for flexible HfO2 RRAM