Amnesty International has accused Ukraine of war crimes during its ongoing military conflict with invading Russian forces.

The humanitarian organization said in a release on Wednesday that the Ukrainian military's tactics "violate international humanitarian law and endanger civilians" by operating weapons out of bases established in residential areas while civilians are present.

Russia has previously been accused by Amnesty International of violating multiple international laws during the war. The organization on Wednesday said that Ukraine's alleged violations "in no way justify Russia's indiscriminate attacks."

"We have documented a pattern of Ukrainian forces putting civilians at risk and violating the laws of war when they operate in populated areas," Amnesty International Secretary General Agnès Callamard said in a statement. "Being in a defensive position does not exempt the Ukrainian military from respecting international humanitarian law."

Amnesty International has accused Ukraine of violating international war laws and endangering civilians during its war with Russia. A Ukrainian soldier is pictured in an armored vehicle on the outskirts of Bakhmut, eastern Ukraine, on July 30, 2022. BULENT KILIC/AFP/Getty

While conducting an investigation of Russian attacks in the Kharkiv, Donbas and Mykolaiv regions of Ukraine between April and July, Amnesty International researchers said they discovered that the Ukrainian military was operating out of civilian buildings in at least 19 towns and villages. The discovery was corroborated by satellite images, according to the release.

The organization said that Ukraine committed "a clear violation of international humanitarian law" by basing at least five military facilities in civilian hospitals. Russian airstrikes on health care facilities have resulted in a significant number of civilian injuries and deaths during the war, according to the World Health Organization.

Amnesty International also discovered that Ukraine had installed military bases in 22 out of 29 schools visited in the Donbas and Mykolaiv regions during the investigation, according to the release. The organization said that Russia later launched strikes on many of the same schools between April and late June, resulting in multiple deaths and injuries.

Following the destruction of schools in at least three towns, Ukraine's military is accused of moving bases to schools in different areas, putting the community surrounding the new bases at risk for similar attacks.

While the bases in schools may not themselves be in violation of international humanitarian law because the schools were not in session, the organization said that Ukraine put bases in schools near houses and apartment buildings without warning the residents or helping them to evacuate.

In some instances, the laws of war dictate that schools and hospitals can become legitimate targets for military attacks, according to the International Committee of the Red Cross.

Amnesty International said that its investigation "does not in any way justify indiscriminate Russian attacks," while urging the Ukrainian military to "distinguish between military objectives and civilian objects and take all feasible precautions" and immediately stop operating out of civilian-populated areas.

"The Ukrainian government should immediately ensure that it locates its forces away from populated areas, or should evacuate civilians from areas where the military is operating," Callamard said. "Militaries should never use hospitals to engage in warfare, and should only use schools or civilian homes as a last resort when there are no viable alternatives."

Amnesty International said that it notified the Ukrainian government about the findings of its investigation on July 29 but had not heard back as of Wednesday.

Newsweek reached out to the Embassy of Ukraine in Washington, D.C., for comment.