i wouldnt use backspace but it deletes stuff automatically without me pressing anything, so im kinda worried it might be a virus
It could be a virus (but normally a virus causes other problems too), it could be a technical issue. You wrote it's a school laptop, so I guess other people used the laptop before. Often people eat something while working on their laptops, food leftovers could cause keyboard problems (for example crumbs that got stuck there).
When I clean a keyboard I use compressed air spray. Maybe you know a friend or a family member that can help you with cleaning the keyboard.
Is there technical support at your school for those laptops?