We consider a special type Cosserat continuum and suggest analogies between quantities characterizing the stress-strain state of the continuum and quantities characterizing physical processes. Such an approach provides us with the ability to derive equations describing electricity, magnetism, and other physical phenomena. This study continues the line of our earlier research. In the present paper, we obtain equations that can be treated as a generalization of Maxwell's equations. The main difference between the proposed equations and classical Maxwell's equations is in the description of magnetic phenomena. In particular, we introduce the concept of a magnetic charge vector and show that this quantity, like the electric charge, satisfies the conservation law and the Gauss law. We are convinced that the magnetic charge vector is the most appropriate physical quantity to characterize the state of a magnetized body. In addition to modeling the electromagnetic field, we make assumptions about how the proposed model can describe the field corresponding to the strong interaction.