Lateral modulation doping of two‐dimensional electron or hole gas