A generalized configuration model with degree correlations and its percolation analysis