Depends on the model. Yes, the lens mount is physically the same size, but the low-end cameras only have electronic connections to the lens. These connections control the focus and aperture. If you mount an older AI lens on this camera you lose all aperture control and metering. Really old non-AI lenses should never be used, as they will damage the camera.
Autofocus on these cameras can only be achieved using lenses with integral focus motors. The higher end cameras will work because they have a focus motor in the camera which drives the lens. The D3200 doesn't have this. Your best bet is to use DX lenses on a camera like this. They are designed to work together beautifully.
Newer lenses are designed to be used with digital sensors and give you the best image quality and performance. Each pixel is basically a bucket that collects light. That light needs to go straight into the bucket to be captured and measured. On older lenses the light coming from the back of the lens spread out rapidly, especially at the edges and corners, which is why the corners and edges will get really dark and soft using the old lenses. Digital-designed lenses keep the light as close to perpendicular to the sensor so the light hits the pixels straight on and the buckets fill up. The lens is said to be "telecentric" (this will be on the quiz).