We consider the elliptic Calogero–Inozemtsev system of \(\textrm{BC}_n\) type with five arbitrary constants and propose R-matrix valued generalization for \(2n\times 2n\) Takasaki’s Lax pair. For this purpose, we extend the Kirillov’s \(\textrm{B}\) -type associative Yang–Baxter equations to similar relations depending on the spectral parameters and the Planck constants. General construction uses the elliptic Shibukawa–Ueno R-operator and the Komori–Hikami K-operators satisfying the reflection equation. Then, using the Felder–Pasquier construction, the answer for the Lax pair is also written in terms of the Baxter’s 8-vertex R-matrix. As a by-product of the constructed Lax pair we also propose a \(\textrm{BC}_n\) type generalization for the elliptic XYZ long-range spin chain, and we present arguments pointing to its integrability.