You can only merge 2 partitions if the unallocated partition is immediately to the right of the partition that you want to merge with. What you can do is back up D, delete it (it will become "Unallocated") and merge it with C to the left of it. Hopefully, without the partition gap in the middle, the 2 partition C will also join together.