The concept of field-effect transistor with ferroelectric gate in combination with the advanced technique of direct domain writing is applied for modulation of transport properties of 2D electron gas located close to the interface in a GaN/AlGaN heterostructure. The ferroelectric Pb(Zr,Ti)O-3 film grown on top of such heterostructure was poled in a controllable way by scanning probe microscope inducing depletion or accumulation effects in the 2D gas depending on the polarity orientation. The artificially created domain arrangements can be projected onto the 2D gas provoking local depletion underneath the poled area. This ferroelectric lithography is potentially interesting for a number of applications as a flexible and nondestructive way of making rewritable patterns on low-dimensional structures with nanoscale resolution. In this work we present the first results on the ferroelectric gate patterning and its impact on the charge concentration and mobility of the 2D gas in the GaN/AlGaN heterostructure.