This paper addresses a production planning problem in a multistage production system consisting of continuous processing resources separated by finite-capacity storage tanks, stimulated by a particular case study in the dairy industry. The problem is formulated as a mixed-integer linear programming (MILP) model that incorporates several distinguishing characteristics of dairy production, such as multistage bulk production, shelf-life requirements, intermediate storage, setups, resource speeds, limitations on minimum and maximum lot sizes, and the conservation of flow among various tanks. The objective is to maximize the total profit while determining the quantity of intermediate products and SKUs processed on various resources, the assignment of products to various resources and intermediate storage tanks, the quantity of each SKU sold, lost sales of each SKU, and waiting times. The determinations often reveal production bottlenecks. The efficiency of the proposed model is illustrated through its application to the milk production plant of a leading dairy company. Special features of the proposed model are highlighted through several examples. The computational performance of the MILP model is examined in several test scenarios.