Cities of the second class and villages may, by ordinance, impose a license tax in an amount which shall be determined by the governing body of such city of the second class or village for each dog or other animal, on the owners and harborers of dogs and other animals, and enforce such license tax by appropriate penalties, and cause the destruction of any dog or other animal, for which the owner or harborer shall refuse or neglect to pay such license tax. Any licensing provision shall comply with subsection (2) of section 54-603 for service animals. Such municipality may regulate, license, or prohibit the running at large of dogs and other animals and guard against injuries or annoyances from such animals and authorize the destruction of such animals when running at large contrary to the provisions of any ordinance.