This paper describes an analytical framework for the weighted max-min flow control of elastic flows in packet networks using PID and PII2 controller when flows experience heterogeneous round-trip delays. Our algorithms are scalable in that routers do not need to store any per-flow information of each flow and they use simple first come first serve (FCFS) discipline, stable in that the stability is proven rigorously when there are flows with heterogeneous round-trip delays. We first suggest two closed-loop system models that approximate our flow control algorithms in continuous-time domain where the purpose of the first algorithm is to achieve the target queue length and that of the second is to achieve the target utilization. The slow convergence  of many rate-based flow control algorithms, which use queue lengths as input signals, can be resolved by the second algorithm. Based on these models, we find the conditions for controller gains that stabilize closed-loop systems when round-trip delays are equal and extend this result to the case of heterogeneous round-trip delays with the help of Zero exclusion theorem. We simulate our algorithms with optimal gain sets for various configurations including a multiple bottleneck network to verify the usefulness and extensibility of our algorithms.