Planting trees around rivers could reduce the height of flooding in towns by up to 20 percent new research suggests.