Generally speaking, try to avoid foods that have been highly processed, as they are less nutritious and healthy, but they also contain the things our body doesn't need or want - sugars, saturated fats, sodium, and preservatives.
Fat by itself isn't bad for our bodies or health, as it is found in many healthy foods, but there is a higher concentration of calories in fatty foods (the most by weight of any nutrient), and it's the easiest nutrient for your body to convert into body fat. Saturated fat (which is solid at room temperature) is the kind of fat found in meat, butter, and cheese, and can increase your risk of high cholesterol and heart disease.
Trans fats (or hydrogenated fats) are created by adding hydrogen to vegetable fats, and are found in deep-fried foods, doughnuts, and some types of margarine - these also raise the amount of cholesterol in your blood, so it's best to avoid them.
Carbohydrates are another source of calories that are not bad or unhealthy for you, but you may want to eat in moderation if you want to lose weight. Our bodies turn carbohydrates into blood sugar to use for energy, so when there is less energy available through blood sugar it will turn to your stored fat for the energy. Be careful when following low-carb diets, as they often heavily restrict carbohydrate intake, but allow high protein/fat intake, which studies have shown has a relationship to higher risk of heart disease.
Avoiding foods with high amounts of sugar is good for two reasons - not only are they associated with higher calories, but eating high-sugar food will also cause a spike in insulin levels, which makes the body think that it has enough energy already, and it should start storing excess energy as fat. Even worse, it is then followed by a drop in insulin level, which makes us feel tired and hungry, so we end up eating more as a result. Try to avoid sodas, as they often contain very high levels of sugar (a 12 ounce can of pop contains the equivalent of 4-5 tablespoons of sugar), or at least switch to diet sodas - if you regularly drink soda, this alone can help you lose 1-2 pounds in a month.
If you find there are certain foods or tastes that you love, read the labels at the grocery store to see if there are different varieties or brands that are healthier, contain less calories, or are less processed. Eating healthy doesn't always mean stopping enjoying things you love, it often just means being smarter about what you eat. Look for substitutes or alternatives that provide similar flavours, tastes, or complement the other foods you're eating (for example, mustard instead of mayonnaise, diet soda instead of regular soda, light cream cheese on a bagel, etc.).
When shopping, make a list in advance, then stick to it - many bad foods are purchased on the spur of the moment when you're hungry, so avoid the temptation of the display aisle.