Self-Organizing Knotted Magnetic Structures in Plasma