I heard from my teacher that during the Weimar era, the German police forces possessed fancy toys such as submarines, tanks, and fighters since the Treaty of Versailles only limited the state's armed forces. Is it true they really possessed such gadgets? I mean it sounds more like a piece of fiction to me.
No. Large items like tanks, submarines, and aircraft were expressly forbidden by the Versailles Treaty and any German development or use of this equipment was either clandestine, very small scale, outside of the country, or just not done at all. The Weimar police though did have access to some military-grade hardware. What your teacher was probably thinking of was the Sicherheitspolizei, a state-affiliated paramilitary that was somewhere between riot police and gendarmes. The Sicherheitspolizei did use armored cars (not restricted by the Treaty), machine guns, and infantry weapons like grenades. The Sicherheitspolizei were used in the suppression of armed uprisings as well as to patrol the borders.
The Sicherheitspolizei was not an innocent example of the militarization of police forces in trying times. The Reichswehr chiefs certainly did see this as a means to contravene the Versailles Treaty's limits on German military manpower. The Sicherheitspolizei was staffed with reliable veterans and other men with military experience. There were plans for an aviation component of the Sicherheitspolizei but that would have been too open of a breach of the Treaty. Instead, the Weimar police usually chartered private aircraft. The existence of the Sicherheitspolizei also caused a good deal of stress between the Republic's government and the Allies; the French in particular recognized the potential for the Sicherheitspolizei to be a shadow auxiliary. But its numbers were too small and the apparent need for the Weimar Republic to have some sort of heavily-armed security force given the number of far-right and far-left insurgents in 1920s Germany meant that these concerns gained very little traction.