Hi and welcome to the forum
Do not get any more fish until this matter is resolved.
As Essjay has pointed out, the most likely reason for the fish dying is ammonia.
Anything that breaks down in the water, be it fish food, fish waste, dead plant, dead fish, etc, produce ammonia. In a healthy tank with an established filter, the ammonia is eaten by beneficial bacteria and converted into nitrite. You get more good bacteria that eat nitrite and convert it into nitrate. You get rid of nitrates by doing water changes.
In a new tank the bacteria is not normally present and you get a build up of ammonia that harms and can kill the fish. A few weeks after the tank has been set up, you get the first colonies of good bacteria that eat the ammonia. A couple of weeks after that you start to get the other good bacteria that eat the nitrite. It normally takes about 4-6 weeks for an aquarium to develop the colonies of good bacteria that keep the ammonia and nitrite levels at 0.
When the ammonia and nitrite levels have gone up and come back down to 0, and the nitrate levels start to go up, the tank will be considered cycled (developed the necessary good filter bacteria) and you can feed the fish once or twice a day and do a 75% water change once a week. Until then you keep feeding down and water changes up. By reducing the food going into the tank, you help to keep the ammonia levels lower. By doing big water changes, you help to dilute any ammonia in the water.
In a newly set up aquarium, you should feed the fish to 2-3 times per week. Don't worry, the fish won't starve. You should also do a 75% water change and gravel clean the substrate 4-8 hours after feeding. And you should monitor the ammonia and nitrite levels and do a 75% water change any day you have an ammonia or nitrite reading above 0, or a nitrate reading above 20ppm.
*NB* Make sure any new water is free of chlorine/ chloramine before it is added to the tank.
The big water changes will not harm the filter bacteria or fish as long as any new water is free of chlorine/ chloramine before it is added to the tank.
-------------------------
During the first month of a tank's cycle, you monitor the ammonia and nitrite levels. You normally get ammonia readings for the first few weeks. The ammonia goes up and as the beneficial filter bacteria build up in numbers they gradually convert the ammonia into nitrite. After a few weeks the ammonia level will suddenly drop to 0 and the nitrite will start to go up. A couple of weeks later the nitrite levels drop to 0 and the nitrates start to go up. You get rid of nitrates by doing water changes.
During the cycling period you do not test for nitrates until the ammonia and nitrite have gone up and come back down to 0. Nitrate test kits will read nitrite as nitrate and give you a false reading. So you monitor ammonia during the first few weeks and then start monitoring nitrite as well. Once they have both gone up and come down to 0, you start monitoring nitrate.
-------------------------
Do not clean the new filter for the first 6-8 weeks. This allows the filter bacteria a chance to settle in properly and stick to the filter media. Two weeks after the filters have finished cycling, you can start to clean the filter.
Established filters should be cleaned at least once a month and every 2 weeks is better.
To clean a power filter or internal sponge/ box filter. You get a bucket of water from the aquarium and squeeze the filter materials out in the bucket of tank water. When they are clean you put them in the aquarium. Wash/ rinse the filter case and impellor assembly (for a power filter) under tap water. Remove any excess tap water by tipping the filter case upside down, then put the filter materials back into the filter and set it back up and get it going.
If you have an undergravel filter, that will be cleaned when you do water changes and gravel clean the substrate. You can buy a basic model gravel cleaner from any pet shop and they are worth getting. You only need a basic model gravel cleaner like the one in the following link. Do not buy the expensive fancy types because they are no better than a base model gravel cleaner.
https://www.about-goldfish.com/aquarium-cleaning.html
----------------
If you have a filter that containers pads/ cartridges that need replacing on a regular basis, do not replace them. Go to the pet shop and buy some sponge for a different brand of filter (I use AquaClear sponges but there are other brands), and use a pair of scissors to cut the sponge to fit in your filter. Keep the sponge and filter pads together for 2 months, then remove the pads and throw them away. Replace the pads with more sponge.
Sponges get squeezed out in a bucket of tank water and will last 10+ years.
You can also get round/ cylindrical sponges for some brands of internal power filter. These round sponges have a hole through the centre and they fit over the intake strainer of most external power filters. They add extra filtration and prevent small fish and bits of plant form being sucked into the filter.