The easiest way to describe a flexible ISA, is to compare it to a non-flexible ISA. A NON-flexible ISA lets you contribute £20,000 each tax year, regardless of whether you withdraw from that ISA in the year or not. So say you added £10k in June, but withdrew £10k in July, you would still only be allowed to add another £10k for the rest of that tax year. It totally ignores how much you withdraw in the year, and only takes into account the money going in.
Whereas a flexible ISA, takes into account how much you withdraw within that tax year. So lets take the same example. If you add £10k in June, but withdraw £10k in July, you would be allowed to contribute a full £20k for the remainder of the tax year.
Lets take an example of somebody who had been contributing into an ISA for some years, and you held a balance of say £50k. This person could withdraw £30k in June, and within that tax year, be able to contribute £50k back in. Thats replacing the £30k which was withdrawn, plus the annual allowance of £20k.