I understand that your disk partitions look like this :
C | unallocated space | D | E
If you wish to increase the size of E, you need to move
the unallocated space to after it.
As unallocated space cannot be moved, you need to move the partitions.
You need to move D on top of the unallocated space, which will then
look like this :
C | D | unallocated space | E
Then repeat the exercise for E, so it looks like :
C | D | E | unallocated space
Only then you will be able to resize E.
As Windows has no tools for moving partitions, you will need to use
a third-party partition editor. An example is
AOMEI Partition Assistant
or its
alternatives.
Warning : Partition editing is dangerous, as any mistake can destroy
your data. Ensure that you have good backups for your data,
and I also recommend an image backup of the entire disk.
Get help from a knowledgeable person if you don't feel safe with this.