Welcome!
We have conflicting information here and I am confused:
it is saying that the battery is low, I cannot find any outlet that allows you to open anywhere to change the batteries, it is showing 19% in my preferences for the keyboard
An A1243 board has no batteries. Never has. It get all power from the computer's USB port.
My Keyboard is permanently attached to my computer
If a true A1243, it is not permanently attached—it unplugs for a computer's USB port.
it is showing 19% in my preferences for the keyboard
The A1243 cannot show a battery level because it has no batteries
No iMac (the subject of this forum section) has a built-in or permanently-attached keyboard
I am very familiar with that board model I've used then since 2007 and have worn out two A1243 boards and several iMacs!
This is the A1243 board. Does yours look the same, including the wire?

Does the warning say "battery is low" or "power is low?" If is it is a "low power" warning, that could indicate the board is attached through a non-powered hub and the board cannot get enough power from the computer.
To clear the air as much as possible, please also tell us what Mac is involved (model AND sub-model) and what macOS version it is running. Also please provide a screen shot of the preference pane that shows the 19% battery charge. That may be very helpful.
I look forward to your additional information.
A