Where is your drawingRectangle() function drawing the rectangle?
Does that position ever change?
If it doesn’t change, all the rectangles are drawn in the same place.
Your sketch has… other issues… but the main concern is that all your rectangles are always being drawn in the same place, no matter what values are stored in any variables…