Let $S$ be the space of $L^2$ zero mean and piecewise constant functions in $\Gamma$. In other words, $$S=\left\{\eta\in L_0^2 : \eta|_{I_i}\in \mathbb{R}\;\forall i=1,...,N\right\}$$where $$L_0^2=\left\{\eta\in L^2 : \int_{\Gamma}\eta =0\right\}$$and each $I_i$ is parametrized interval of $\Gamma$,$$I_i=\left\{\alpha \mathbf{x}_i+(1-\alpha)\mathbf{x}_{i+1},\;\alpha\in [0,1]\right\}\text{ and }\mathbf{x}_{N+1}=\mathbf{x}_1.$$
Some notes that I have say that the dimension of $S$ is $N-1$ and that its base is:$$\left\{\eta_i=\frac{1}{h_i}\psi_i-\frac{1}{h_1}\psi_1\right\}_{i=2}^N$$where $\psi_i$ is the characteristic function of $I_i$ and for $i=1,\ldots,N$ $$h_i=|I_i|=\int_{I_i}1.$$
However, I do not understand where the basis comes from and why only $N-1$ basis functions are needed. Moreover, I do not get the idea of having $-\frac{1}{h_1}\psi_1$ in each basis function, I guess that is something related with the fact that $S$ functions should be zero mean but I do not know why it works.
As above, $S$ is the space of zero mean and piecewise constant functions on the $N$ intervals $\{I_i\}$. A piecewise constant function on $N$ intervals can have any value assigned to each of the intervals, so you can think of it as being an $N$ dimensional vector. Since there are $N$ degrees of freedom in specifying it, the requirement of being zero mean reduces the overall dimension by $1$ to be $N - 1$.
The proposed basis of this $N - 1$ dimensional space is $$\left\{\eta_i=\frac{1}{h_i}\psi_i-\frac{1}{h_1}\psi_1\right\}_{i=2}^N$$ The reason they are subtracting off $\frac{1}{h_1}\psi_1$ is to ensure that each of these functions $\eta_i$ has zero mean, and is therefore in the space. $$\int \eta_i = \frac{1}{h_i}\int \psi_i-\frac{1}{h_1}\int \psi_1 = 1 - 1$$
Now a general piecewise constant function can be represented as $$\sum_{i=2}^N \alpha_i \eta_i = \sum_{i=2}^N\frac{\alpha_i}{h_i} \psi_i-\frac{\sum_{i=2}^N \alpha_i}{h_1}\psi_1$$