MAYBE there is a problem with the drivers for these two devices. Try this sequence to remove and replace the drivers.
1. SAFE BOOT into Windows where you can get things working. In the bottom left search window type Device Manager and go there.
2. Expand the Keyboards item and find your keyboard. If there are several and you do not know which, do this for all. RIGHT-click on each and Uninstall the device.
3. When those are done, go to Mice and Other Pointing Devices and do the same.
4. Back out of Device Manager.
5. UNPLUG BOTH the keyboard and mouse.
6. Reboot your machine. It will tell you of errors - no keyboard and no mouse. Let it finish rebooting, then hold in the case front power button for several seconds to force it to shut down.
7. Plug in the keyboard only and boot up. You should see a little window telling you a new device has been found and its driver is being installed. When the entire boot is finished try the keyboard - it should be working now. Shut down.
8. Same thing again: plug in the MOUSE, too, then boot up. Again it should find the mouse and load its driver. Check whether it works. If it does, you have fixed the problems.