One of the difficulties related to French pronunciation is that it is not a phonetic language.
In a phonetic language each letter has a single corresponding sound and spelling matches pronunciation.
French and English are not phonetic: they have letters that can be pronounced in different ways or sometimes not at all.
The basic rule of French pronunciation is that the final consonant is not pronounced, but there are many exceptions.
One of the first tips I give to my students to improve their pronunciation is:
the consonants of the words DePoSiT plus X and Z are not pronounced when they are at the end of the words:
Solda(t), avoca(t), pri(s),bra(s), dra(p)
All the others consonants are pronounced unless they have a R, M, N in front of them.
San(g), ban(c), por(c)
You read D, with a vowel in front of it, if it is at the end of a name:
AlfreD, ConraD, DaviD
Remember that there are many exceptions.